Tool for extracting translations from Angular app using regex
Nodejs 12 or higher need to be installed first
npm install -g ngx-i18n-extract-regex-cli
or
yarn global add ngx-i18n-extract-regex-cli
Go to command line and type
ngx-i18n-extract-regex --help
Option | Type | Default | Description |
---|---|---|---|
library | transloco, ngx-translate |
transloco |
Target i18n library |
cwd | string | src |
Current working directory |
source | string[] | app/**/*.ts', 'app/**/*.html |
Path to source files |
langs | string[] | assets/i18n/*.json |
Path to language files |
default-value | string | ███ |
Default string |
dry-run | boolean | false |
Run process without writing results |
encoding | utf-8, ascii, utf8, utf16le, ucs2, ucs-2, base64, latin1, binary, hex |
utf-8 |
Encoding for writing results |
Copyright © 2024 Dominik Hladik
All contents are licensed under the MIT license.