dayjs('2016年10月11日', 'YYYY年MM月DD日') get Invalid Date
- Dominant language
- JavaScript
- Stars
- 48.7k
- Forks
- 2.5k
- PR merge metrics
- No merged PRs in 30d
Description
**Describe the bug**
Use the latest version of dayjs
```
dayjs('2016年10月11日', 'YYYY年MM月DD日')
```
result
`M {$L: 'en', $d: Invalid Date, $x: {…}, $y: NaN, $M: NaN, …}`
but in 1.8.21
result
`M {$L: 'en', $u: undefined, $d: Tue Oct 11 2016 00:00:00 GMT+0800 (中国标准时间), $y: 2016, $M: 9, …}`
Why can't the content containing Chinese be parsed normally in the latest version?
Contributor guide
Research direction
No files or tests are named. Reproduce the provided Chinese date parsing example on the latest version and compare it with 1.8.21, then trace the parsing entry point and existing date-parsing tests. Done means the documented input produces the expected date instead of Invalid Date, with regression coverage.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- api
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100