首页 > 其他 > 详细

[Angular] Introduction to Angular Internationalization (i18n)

时间:2019-02-07 21:36:20      阅读:179      评论:0      收藏:0      [点我收藏+]

To add translation to the application:

<button (click)="onEditCourse()" i18n>Edit button</button>

‘i18n‘ is for Angular CLI to extract all the string which need to be translated.

 

Run:

ng xi18n

 

It will generate messages.xif, this file will be sent to the translator interface, then we can add translation for the application.

 

It is possible to provide custom message, description or even id for the translation, but it is not recommended.

技术分享图片

技术分享图片

技术分享图片

[Angular] Introduction to Angular Internationalization (i18n)

原文:https://www.cnblogs.com/Answer1215/p/10353818.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!