Created
July 3, 2022 19:00
-
-
Save batazo/6784936d167fde2085d9b44e2f29cf37 to your computer and use it in GitHub Desktop.
Temporal Functions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const date = Temporal.Now.plainDateISO(); // Gets the current date | |
date.toString(); // returns the date in ISO 8601 date format | |
// If you additionally want the time: | |
Temporal.Now.plainDateTimeISO().toString(); // date and time in ISO 8601 format |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment