ISO Day of Week2.1.0+
moment().isoWeekday(Number);
moment().isoWeekday(); // Number
Gets or sets the ISO day of the week with 1
being Monday and 7
being Sunday.
As with moment#day
, if the range is exceeded, it will bubble up to other weeks.
moment().isoWeekday(1); // Monday
moment().isoWeekday(7); // Sunday
A day name is also supported. This is parsed in the moment's current locale.
moment().isoWeekday("Sunday");
moment().isoWeekday("Monday");
当前内容版权归 momentjs.com 或其关联方所有,如需对内容或内容相关联开源项目进行关注与资助,请访问 momentjs.com .