I18n: Improve tooling (#56731)

* Delete en-US.json before extracting strings so it's always up to date

* Add 'comment' to message jsons

* Enable Pseudo-locale option only in dev mode

* don't load english messages

* fix package.json

* fix
This commit is contained in:
Josh Hunt
2022-10-12 07:51:16 -04:00
committed by GitHub
parent 80ede174dd
commit b7d969baf1
8 changed files with 51 additions and 30 deletions
+2 -1
View File
@@ -50,7 +50,8 @@
"watch": "yarn start -d watch,start core:start --watchTheme",
"ci:test-frontend": "yarn run test:ci && yarn grafana-toolkit node-version-check",
"postinstall": "husky install",
"i18n:extract": "yarn run i18next -c public/locales/i18next-parser.config.js 'public/**/*.{tsx,ts}' 'packages/grafana-ui/**/*.{tsx,ts}' && node ./public/locales/psuedo.js",
"i18n:clean": "rimraf public/locales/en-US/grafana.json",
"i18n:extract": "yarn i18n:clean && yarn run i18next -c public/locales/i18next-parser.config.js 'public/**/*.{tsx,ts}' 'packages/grafana-ui/**/*.{tsx,ts}' && node ./public/locales/psuedo.js",
"i18n:compile": "echo 'no i18n compile yet, all good'",
"betterer": "betterer",
"betterer:merge": "betterer merge",