当前位置: 软件>JavaScript软件
i18next
本文导语: i18next 在客户端实现站点的本地化,i18next 从服务端获取资源然后对标签为data-i18n的内容进行翻译。示例:// given loaded and merged dictionaries in i18next.js to: { "en_US": { "ns.special": { "app": { ...
i18next 在客户端实现站点的本地化,i18next 从服务端获取资源然后对标签为data-i18n的内容进行翻译。
示例:
// given loaded and merged dictionaries in i18next.js to:
{
"en_US": {
"ns.special": {
"app": {
"name": "i18n",
"insert": "you are __youAre__",
"child": "__count__ child",
"child_plural": "__count__ children"
}
},
"ns.common": {}
},
"en": {
"ns.special": {
"app": {
"area": "Area 51"
}
},
"ns.common": {}
},
"dev": {
"ns.common": {
"app": {
"company": {
"name": "my company"
}
},
"add": "add"
},
"ns.special": {
"nav": {
"1": "link1",
"2": "link2",
"home": "home"
}
}
}
}您可能感兴趣的文章:
本站(WWW.)旨在分享和传播互联网科技相关的资讯和技术,将尽最大努力为读者提供更好的信息聚合和浏览方式。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。