Linux command
ng-extract-i18n 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
Extract messages
ng extract-i18n
Extract to specific format
ng extract-i18n --format [xlf]
Extract to output path
ng extract-i18n --output-path [locale/]
Extract for specific project
ng extract-i18n --project [my-app]
说明
ng extract-i18n extracts internationalization messages from Angular templates. Generates translation source files for localization workflow. Supports XLIFF, XMB, and JSON formats.
参数
- --format _format_
- Output format (xlf, xlf2, xmb, json, arb).
- --output-path _path_
- Output directory.
- --out-file _file_
- Output filename.
- --project _name_
- Project to extract from.
- --progress
- Show progress.
FAQ
What is the ng-extract-i18n command used for?
ng extract-i18n extracts internationalization messages from Angular templates. Generates translation source files for localization workflow. Supports XLIFF, XMB, and JSON formats.
How do I run a basic ng-extract-i18n example?
Run `ng extract-i18n` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does --format _format_ do in ng-extract-i18n?
Output format (xlf, xlf2, xmb, json, arb).