0.1.1 • Published 5 years ago
padati v0.1.1
Padati
A Useful Date and Time Parser!
Example
index.js:
const Padati = require("Padati")
console.log(Padati().Day) //=> Whatever current day it isRules
- You must use Padati (or whatever you named the import) as a function, like this:
Padati()NOT like this:
Padati- You must capitalize the item your getting off of the object, otherwise it won't work:
Padati().SecondNOT like this:
Padati().secondItems from the import
Padati().Day- Returns the current dayPadati().Month- Returns the current monthPadati().Year- Returns the current yearPadati().Hour- Returns the current hourPadati().Minute- Returns the current minutePadati().Second- Returns the current secondPadati().Milliseconds- Returns the current millisecondPadati().Timezone- Returns the current timezone
Global Scripts
Use padati when you installed it globally or...
... Create a script, with the script body as padati.
It will return a kind-of similar object like this:
{
Day: 9,
Month: 4,
Year: 2021,
Hour: 17,
Minute: 2,
Second: 9,
Milliseconds: 291,
Timezone: 'Eastern Daylight Time'
}But differently, of course, depending on where & what time you are in :)
License
MIT