Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature:国际化支持 #15

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open

Conversation

zzhutianyu
Copy link

  1. 国际化支持
  2. 脚步适配目录更改
  3. 添加新语言脚本,以及从默认语言目录更新文件脚本

1. 国际化支持
2. 脚步适配目录更改
3. 添加新语言脚本,以及从默认语言目录更新文件脚本
@zzhutianyu
Copy link
Author

还有点bug。。

@miloyip
Copy link
Owner

miloyip commented Apr 12, 2021

之前在想这个功能的时候,我有一些想法,可以讨论一下。
不改变预设(英文)的 JSON,只加入一个大 localization JSON 如 zn.json["id" : { "id": "localized id", "author": "localized author", ... }, ...]
可定期用脚本把英文的 database 更新这 JSON 中未有的 id。
这个做法的好处是,localization 不需要考虑 graph 结构和中英文同步问题。

@zzhutianyu
Copy link
Author

是个不错的方法,方便同步更新维护内容,我写的时候,只考虑了在不太修改页面逻辑完全兼容原本的逻辑,直接换一套语言版本的加载比较省事

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants