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

l18n #86

Closed
gnehs opened this issue Oct 10, 2018 · 2 comments
Closed

l18n #86

gnehs opened this issue Oct 10, 2018 · 2 comments
Labels

Comments

@gnehs
Copy link
Owner

gnehs commented Oct 10, 2018

No description provided.

@gnehs gnehs added the frontend label Oct 10, 2018
@gnehs
Copy link
Owner Author

gnehs commented Jan 19, 2019

String.prototype.render = function (context) {
  return this.replace(/{{(.*?)}}/g, (match, key) => context[key.trim()]);
};
"{{name}}很厉name害,才{{ age  }}岁".render({ name: "jawil", age: "15" }); //"jawil很厉name害,才15岁"

jawil/blog#32

@gnehs
Copy link
Owner Author

gnehs commented Jan 20, 2019

  • 以英文作為後備方案
  • 英文翻譯
  • 首頁
  • 隨機圖片來源
  • 安裝頁面
  • 可自訂語言

@gnehs gnehs closed this as completed Jun 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant