Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hermes Invalid Date with dateFormat #186

Open
imanshul opened this issue Jul 12, 2024 · 1 comment
Open

Hermes Invalid Date with dateFormat #186

imanshul opened this issue Jul 12, 2024 · 1 comment

Comments

@imanshul
Copy link

imanshul commented Jul 12, 2024

When using dateFormat with hermes engine, we are getting Invalid Date as error

let myDate = dateFormat("06 Sep 2024", "dd mmm yyyy");
console.log(myDate);

It gives error while formatting date string to "dd mmm yyyy" format

@chase-manning
Copy link
Collaborator

@imanshul Try reading the docs again. It looks like your date string isn't formatted correctly. Think it should be month first right" Like Sep 6 2024.

https://github.com/felixge/node-dateformat/blob/master/Readme.md?plain=1#L40

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants