File tree Expand file tree Collapse file tree 3 files changed +26
-0
lines changed Expand file tree Collapse file tree 3 files changed +26
-0
lines changed Original file line number Diff line number Diff line change 33.vscode
44coverage
55dist
6+ src /i18n /transifex_input.json
67node_modules
78/docs /api
89.env.private
10+ /temp /
Original file line number Diff line number Diff line change 11# Documentation CLI usage: https://github.com/documentationjs/documentation/blob/master/docs/USAGE.md
22
3+ i18n = ./src/i18n
4+ transifex_input = $(i18n ) /transifex_input.json
5+ transifex_utils = $(i18n ) /scripts/transifex-utils.js
6+
7+ # This directory must match .babelrc .
8+ transifex_temp = ./temp/babel-plugin-formatjs
9+
310doc_command = ./node_modules/.bin/documentation build src -g -c ./docs/documentation.config.yml -f md -o ./docs/_API-body.md --sort-order alpha
411cat_docs_command = cat ./docs/_API-header.md ./docs/_API-body.md > ./docs/API.md
512
@@ -24,3 +31,19 @@ docs-watch:
2431
2532docs-lint :
2633 ./node_modules/.bin/documentation lint src
34+
35+
36+ .PHONY : requirements
37+ requirements : # # install ci requirements
38+ npm ci
39+
40+ i18n.extract :
41+ # Pulling display strings from .jsx files into .json files...
42+ rm -rf $(transifex_temp )
43+ npm run-script i18n_extract
44+
45+ i18n.concat :
46+ # Gathering JSON messages into one file...
47+ $(transifex_utils ) $(transifex_temp ) $(transifex_input )
48+
49+ extract_translations : | requirements i18n.extract i18n.concat
Original file line number Diff line number Diff line change 1212 "docs" : " jsdoc -c jsdoc.json" ,
1313 "docs-watch" : " nodemon -w src -w docs/template -w README.md -e js,jsx --exec npm run docs" ,
1414 "lint" : " fedx-scripts eslint --ext .js --ext .jsx ." ,
15+ "i18n_extract" : " fedx-scripts formatjs extract" ,
1516 "snapshot" : " fedx-scripts jest --updateSnapshot" ,
1617 "start" : " fedx-scripts webpack-dev-server --progress" ,
1718 "test" : " fedx-scripts jest --coverage" ,
You can’t perform that action at this time.
0 commit comments