Error in parsing array format date
- Dominant language
- JavaScript
- Stars
- 48.7k
- Forks
- 2.5k
- PR merge metrics
- No merged PRs in 30d
Description
**Describe the bug**
```
import dayjs from 'dayjs'
import arraySupport from 'dayjs/plugin/arraySupport'
dayjs.extend(arraySupport)
use:
dayjs([2010, 1, 14]).format('YYYY/MM/DD')) return 2010/02/14
```
**Expected behavior**
```
dayjs([2010, 1, 14]).format('YYYY/MM/DD')) return 2010/01/14
```
**Information**
- Day.js Version 1.11.8
- OS: Mac OS
- Browser: Google Chrome v115
- Time zone: Eastern Daylight Time
Contributor guide
Research direction
Start with the arraySupport plugin and reproduce the supplied Day.js 1.11.8 example. Trace how the array's month value is interpreted, then confirm the intended month convention and verify that formatting the reported input produces the agreed result.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100