Check out this scrimba moment guide if you're just starting. This means that operations like add, subtract, or set change the original moment object.
In a later release, the parser will default to using strict mode.
This results in a date with a fixed offset: "2013-01-01T-" Note that if you use moment() or moment.utc() to parse a date with a specified offset, the date will be converted from that offset to either local or UTC: This date is shifted by 8 hours, moving from 2 to -6 (the offset of the local machine) 2013-02-08 # A calendar date part 2013-W06-5 # A week date part 2013-02-08T09 # An hour time part separated by a T 2013-02-08 09 # An hour time part separated by a space 2013-02-08 # An hour, minute, and second time part 2013-02-08 09 # -HH:mm Strict mode is the recommended mode for parsing dates.
You should always use strict mode if your code base will allow it.
The core library provides functionality related to adjusting times based on an offset value.
It does not provide support for adjusting dates based on time zone data - this is provided by the Moment Time Zone library.