-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
customParseFormat strict cannot parse 1-2 digit milliseconds #1331
Comments
Is there any progress with this? Is this a bug or am I missing some configuration properties? |
@iamkun can you give any information about this? |
I am having a similar issue, e.g. dayjs('04:59:00.900 PM', 'h:mm:ss.SSS A', true) returns InvalidDate. Works in moment. |
The problem is that dayjs uses PR #1914 solves this topic. |
I'm facing the same issue with the formatIssue while using "S" and "SS" in the format Works fine |
When using customParseFormat with strict mode enabled cannot parse milliseconds in 1-, 2-digit (S or SS pattern). Results in "Invalid Date".
Only 3-digits are parsed fine.
YYYY-MM-DDTHH:mm:ss.SSS pattern is OK
YYYY-MM-DDTHH:mm:ss.SS and YYYY-MM-DDTHH:mm:ss.S patterns are not OK
See jsfiddle: https://jsfiddle.net/4t5yk0ju/1/
The text was updated successfully, but these errors were encountered: