-
-
Notifications
You must be signed in to change notification settings - Fork 34
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
Dates are output as strings in ISO format #229
Comments
Thank you for open this issue, I will look on it soon. |
A |
Great ideas, I will definitely check them out. So far, I was considering another cloning function, the one using JSON is primitive, which your example demonstrates perfectly. By the way, contributions to this project are very welcome, so feel free to submit a PR 😃 I'm planning to tackle this issue soon. Currently, along with several contributors from exceljs, we are trying to clear the PR list (currently at 70 PRs 🙈 ). We coordinate on Discord: https://discord.gg/BqTQGHDKw8. I mention this because this project is based on exceljs, so working there brings double benefits :D |
It is impossible to output any Date data to Excel. exceljs expects date data to be Javascript Date object to output them properly so that Excel can handle them. However, after fixing #137 all dates are passed to exceljs as strings (in ISO format). The reason is that
JSON.parse(JSON.stringify(vm))
doesn't make an exact deep copy.JSON.stringify(vm)
turns dates in ISO formatted strings butJSON.parse(....)
does not turn them back to Date objects. It rather leaves them as strings.We either need the proxy solution or a proper deep copy.
The text was updated successfully, but these errors were encountered: