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

Time / date formatters stop render when issue is encountered. #1688

Closed
cloke opened this issue Jun 15, 2022 · 0 comments · Fixed by #1887
Closed

Time / date formatters stop render when issue is encountered. #1688

cloke opened this issue Jun 15, 2022 · 0 comments · Fixed by #1887

Comments

@cloke
Copy link

cloke commented Jun 15, 2022

Environment

  • Ember Version: 4.4.1
  • Ember CLI Version: 4.4.0
  • Ember Intl Version: 6.0.0-beta.2
  • Browser(s): Chrome / Safari
  • Node Version: 16

Steps to Reproduce

When passing a value to format-date or format-time it results in an error that prevents any further render of the page. This becomes problematic when displaying a lot of table data from a server. We've added all sorts of checks in the template or model to try and prevent these, but I was curious if this is intended behavior or would it make more sense to just render a string like invalid at the library level?

Error:

Unhandled Promise Rejection: Error: [@formatjs/intl Error FORMAT_ERROR] Error formatting date.

date value is not finite in DateTimeFormat format()
format@[native code]
@[native code]
formatDate@
formatDate@[native code]
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

Successfully merging a pull request may close this issue.

1 participant