Skip to content

Conversation

@tmkasun
Copy link

@tmkasun tmkasun commented Jul 13, 2019

What: Posible implementation for #38 feature request

Why: Without these changes, Users can't generate locale ids and messages that are used in intl.formatMessage function calls as direct object argument.

i:e

Alert.error(intl.formatMessage({
                id: 'Supported.file.type',
                defaultMessage: 'Supported File Type.',
            }));

Above id (Supported.file.type) and message will not be available in generated locale file, Unless extractFromFormatMessageCall is set to true in babel-plugin-react-intl plugin configurations.

How: Changes were done to pass the extractFromFormatMessageCall parameter to babel-plugin-react-intl configurations via the extract-react-intl library interfaces.

So that this PR depends on: akameco/extract-react-intl#21

Checklist:

  • Documentation
  • Tests N/A
  • Ready to be merged
  • Added myself to contributors table

@tmkasun
Copy link
Author

tmkasun commented Jul 17, 2019

Hi @akameco ,

Could you please review this PR

@akameco
Copy link
Owner

akameco commented Aug 20, 2019

I'm sorry for the late review.
Supported all babel-plugin-react-intl options in #42 .

@akameco akameco closed this Aug 20, 2019
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.

2 participants