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

Include all messages for the original language in the react-intl output #19

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Include all messages for the original language in the react-intl output #19

wants to merge 1 commit into from

Conversation

rescribet
Copy link
Contributor

First off, awesome project. It makes working with react-intl a lot easier, especially for small scale translations (in comparison to react-intl-translations-manager + serge + pootle).

When trying this library to build the message bundles for react-intl, I noticed the file for the original language only contained the default message when an interpolation was given.

I figured since the messages are the defaults and therefore already in the code one might one of two things;

  • Not include the original lang in config.langs or disregard the outputted <defaultLang>.reactIntl.json file.
  • Strip the default language from the react props during build, and load the translations for the original language in the same way as all the translated locales.

This PR shouldn't change behaviour for the first case, but it'll make the second case possible

@rescribet
Copy link
Contributor Author

rescribet commented Oct 25, 2018

This works again after rebasing on master. @guigrpa What do you think of the behaviour, should it be behind a flag?

@rescribet rescribet mentioned this pull request Oct 27, 2018
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 this pull request may close these issues.

1 participant