According to Moment.js documentation, ‘month’ uses an array and the indices of an array are zero-based. Therefore, January is set to ‘0’ and December is set to ’11’.
For example, moment().month('November'); prints ’10’.
According to Moment.js documentation, ‘month’ uses an array and the indices of an array are zero-based. Therefore, January is set to ‘0’ and December is set to ’11’.
For example, moment().month('November'); prints ’10’.