convert moment date to utc format moment
moment(timestamp).toISOString(true)
convert moment date to utc format moment
moment(timestamp).toISOString(true)
typescript get the time moment
/* Here you are assigning an instance of momentjs to CurrentDate: */
var CurrentDate = moment();
/* Here just a string, the result from default formatting
of a momentjs instance: */
var CurrentDate = moment().format();
/* And here the number of seconds since january of... well, unix timestamp: */
var CurrentDate = moment().unix();
/* And here another string as ISO 8601
(What's the difference between ISO 8601 and RFC 3339 Date Formats?): */
var CurrentDate = moment().toISOString();
/* And this can be done too: */
var a = moment();
var b = moment(a.toISOString());
console.log(a.isSame(b)); // true
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us