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

MessageFormat translations resulting in warning messages #32

Open
fidelpita opened this issue Apr 4, 2020 · 0 comments
Open

MessageFormat translations resulting in warning messages #32

fidelpita opened this issue Apr 4, 2020 · 0 comments

Comments

@fidelpita
Copy link

When using MessageFormat translations such as:
console.log(_t("someContext_{NUM, plural, one{1 hamburger} other{# hamburgers}}", { NUM: 2 }));
the following warning is generated:
Expected '===' and instead saw '=='
at the following return line:

var es = function(n, ord) {
  if (ord) return 'other';
  return (n == 1) ? 'one' : 'other';
};

Perhaps the messageformat dependency needs to be updated?
Context: using the latest version of create-react-app

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

1 participant