0

Is there a simple way to convert a :

new Date()

into a string with the full format like this :

"YYYY-MM-DDThh:mm:ssZ"

Ellone
  • 3,644
  • 12
  • 40
  • 72

1 Answers1

1

You need

new Date().toISOString()

This is zulu time as denoted by "Z" in the last.

void
  • 36,090
  • 8
  • 62
  • 107