Closed alkuma closed 5 years ago
If anyone could point to the code that parses the xlf2 file I could attempt to submit a patch myself
The first thing I would suggest is to update your version of the CLI. The latest version as of today is 1.3.1 which is much more up to date than the beta you are currently using. Please report back after updating.
can you give us the content of the file "messages.xliff2.xlf" ? I suspect that there is a missing closing tag or quote in your translations
Closing as no further feedback was provided.
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.
Bug Report or Feature Request (mark with an
x
)Versions.
angular-cli: 1.0.0-beta.28.3 node: 6.9.1 os: linux x64
Repro steps.
Created the xlf2 file for the project using the command ng-xi18n --i18nFormat=xlf2 --outFile=app/locale/messages.xliff2.xlf Next, performed the translation to create app/locale/messages.ts-TH.xliff2.xlf to create translation created i18n-providers.ts (attached) i18n-providers.ts.txt
modified main.ts (attached) to get translation providers before bootstrap. Upon running the application (via chrome) application fails to boot with the following error in console log main.ts.txt
The log given by the failure.
console.log.txt
Desired functionality.
There seems to be some issue with how the xlf2 file is being parsed. This is a bug that needs to be fixed. If any workaround is possible, please suggest.
Mention any other details that might be useful.
Instructions followed were from: https://angular.io/guide/i18n https://stackoverflow.com/a/43369141/41284 - used rxjs instead of systemjs locale value is hardcoded to ts-TH in the index.html to simulate this issue also noticed a similar issue https://github.com/angular/angular-cli/issues/6418 but raising this since the way we simulated the issue was slightly different so it could be a different root cause