Date related functions.
- Source:
Methods
(static) centuryFinder(year) → {number}
Returns a date in 20XX or 19XX starting from a number less than 100. (i.e. '85 is 1985)
Parameters:
Name | Type | Description |
---|---|---|
year |
number | The year to be converted. |
- Source:
Returns:
The converted year.
- Type
- number
(static) formatDate(timestamp) → {string}
Format a UNIX timestamp into the YYYY-MM-DD format.
Parameters:
Name | Type | Description |
---|---|---|
timestamp |
number | The timestamp to be formatted. |
- Source:
Returns:
The formatted timestamp.
- Type
- string
(static) formatTime(timestamp) → {string}
Format a UNIX timestamp into the HH:MM:SS format.
Parameters:
Name | Type | Description |
---|---|---|
timestamp |
number | The timestamp to be formatted. |
- Source:
Returns:
The formatted timestamp.
- Type
- string