react-intl-cli
v0.1.2
Published
React-Intl CLI for your React project
Downloads
6
Maintainers
Readme
React-Intl CLI for your React App
react-intl-cli
- command line tools for manipulating
react-intl message catalogues.
Installation
You could install react-intl-cli
global or local.
Global Installation
Using npm:
npm install --global react-intl-cli
Using yarn:
yarn global add react-intl-cli
Local Installation
Using npm:
npm install -D react-intl-cli
Using yarn:
yarn add -D react-intl-cli
and add script to your package.json
file:
{
"scripts": {
"extract-translations": "react-intl-cli extract"
}
}
Usage
For now react-intl-cli
provides the only extarct
command.
Extract command
Extracts messages from source files and creates a message catalog for each language.
If you install react-intl-cli
globally you could run it in your command line:
react-intl-cli extract
or with custom options:
react-intl-cli extract [option] [glob-patterns...]
to show available options run help:
react-intl-cli extract -h
If you install locally just run:
npm run extract-translations
License
This package is licensed under MIT license.