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 Intl::DateTimeFormat default constructor fails with default locale and options #198

Open
1 task
anramanath opened this issue Aug 20, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@anramanath
Copy link

anramanath commented Aug 20, 2024

Bug Description

Using the Intl.DateTimeFormat constructor with default (undefined) fails even though the parameter is optional
const formatter = new Intl.DateTimeFormat(undefined, options);

  • The issue is reproducible with the latest version of RNW 0.73.7.

Hermes git revision (if applicable):
React Native version: 0.73.7
OS: Windows 11
Platform (most likely one of arm64-v8a, armeabi-v7a, x86, x86_64):

Steps To Reproduce

  1. Create RNW application follow these directions
  2. Modify Hermes version to ensure Hermes Internationalization is enabled (0.1.27+)
  3. Try using formatter = new Intl.DateTimeFormat(undefined, options); to format any date and display the text
  4. Observe crash

code example:
const formatter = new Intl.DateTimeFormat(undefined, options);

The Expected Behavior

Formatted date, no crash.

@anramanath anramanath added the bug Something isn't working label Aug 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant