Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

Latest commit

 

History

History
executable file
·
8 lines (7 loc) · 411 Bytes

i18n.md

File metadata and controls

executable file
·
8 lines (7 loc) · 411 Bytes

i18n

  1. 修改创建组件的模板
  2. 初始加载使用浏览器默认语言 (通过: accept.language(['en', 'zh']), 见官方例子)
  3. 后续过程中如果前端 locale 手动改变,则单独请求 locale 文件 (server.js 需要单 独的 locale 路由)
  4. build 的时候用 default-lang.js 脚本生成 en/zh.json 文件, messages 导出后 key/id 不能重复
  5. 逻辑合并到数据流