本文介绍了Angular 2 i18n-internationalisation:message.xlf为空的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在遵循有角度的国际化食谱: https://angular.io/docs/ts/latest/cookbook/i18n.html#!#angular-i18n

I 've been following the angular cookbook for internationalization : https://angular.io/docs/ts/latest/cookbook/i18n.html#!#angular-i18n

经过长时间的依赖调试之后,我设法生成了一个message.xlf文件,没有任何错误,但是,没有提取任何内容,xlf为空.

after a long dependency debugging time, i manage to generate a message.xlf file, without any error but,nothing has been extracted, the xlf is empty.

似乎在我的标签中看不到i18n ...

it seems to not see the i18n in my tags...

有人能解决这个问题吗?

is there anyone who managed to solve this?

message.xlf

message.xlf

<?xml version="1.0" encoding="UTF-8" ?> <xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2"> <file source-language="en" datatype="plaintext" original="ng2.template"> <body> </body> </file> </xliff>

<?xml version="1.0" encoding="UTF-8" ?> <xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2"> <file source-language="en" datatype="plaintext" original="ng2.template"> <body> </body> </file> </xliff>

推荐答案

我遇到了同样的问题,在我的情况下是angular编译器+打字稿2.1.4,回滚到版本2.0.10解决了该问题.

I face the same problem, in my case was the angular compiler + typescript 2.1.4, rollback to version 2.0.10 solves the problem.

这篇关于Angular 2 i18n-internationalisation:message.xlf为空的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-02 00:19