Translation Recommendations
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 25/100
- Issue 类型
- 文档
- 描述清晰度
- 需要澄清
- 活跃度
- 停滞
- 技术栈
- react, typescript
调研方向
从仓库的 README 以及链接的 markdown documentation、playground-examples 和 tsconfig-reference 目录开始。检查当前如何将 React-intl 本地化用于导航栏,以及翻译后的示例是如何组织的。该 issue 没有指定目标文件或验收标准,因此要完成它,需要定义范围并记录已达成一致的翻译建议。
由索引模型根据 Issue 内容生成。
描述
How To Contribute
-
Join the TypeScript Discord - come say hi the
ts-web-translate -
Follow the instructions on the README of this repo to get set up.
All Markdown Docs
Each translatable page is a unique markdown file which can be uniquely handled per language. Any markdown file not found will be replaced with English when not present.
Website
The website supports localization via React-intl, as of today only the navigation bar it translatable, but with time this will grow. The infra just came in with https://github.com/microsoft/TypeScript-Website/pull/180
There are a series of keys and values for each language, with a fallback to English if you miss something. The TypeScript compiler will keep it all in check.
Playground
You can cover the examples in the dropdown in the playground (and in the site footer on desktops.) Full docs here
- Make a subfolder with the code of the language in the copy folder of the 'playground-examples'
- Ensure the filename are the same as English, (you can provide a different title via the JSON headers in the ts/js files)
- Check out this folder
- Ensure the filename is the same (we can provide a different title via the YML headers in the markdown files)
Recommendations
I'm pretty new to the translation game, but here's some notes from working with people so far on how translations can culturally work in the TS website.
Translate code to be a cultural fit. E.g.
const helloWorld = "Hi"
to
const olaMundo = "Olá`
Translate names in example
const user = { name: "John" }
to
const usar = { name: "João" }
Note: we aim to have a diverse set of nationalities and genders in our examples, so I'd recommend not changing all of them, but try keep it feeling like it was written with that in mind also.
Translate Technical Terms, but keep English around
This one is nuanced, but a term like Mapped Type is the name for this:
type MyPartialType<Type> = {
// For every existing property inside the type of Type
// convert it to be a ?: version
[Property in keyof Type]?: Type[Property];
};
So, if you translate it to "mapeada type", then provide a reference to the original name the first time it is used: "mapeada type (Mapped Type em inglês)" so that readers can know how to find the English resources on a topic.
- 主要语言
- JavaScript
- 星标
- 124
- 派生
- 128
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
我们还没有检查这个项目的环境配置文件。先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
microsoft/TypeScript-Website-Localizations 的其他 Issue
-
No hackerone未关闭
难度 5/5 一周以上 新手友好度 10/100
-
难度 5/5 一周以上 新手友好度 1/100
-
Ignite nation未关闭
难度 5/5 一周以上 新手友好度 1/100
-
难度 5/5 一周以上 新手友好度 20/100
microsoft/TypeScript-Website-Localizations#195 · 11 条评论 · 1 个 reaction ·
-
难度 1/5 1 小时以内 新手友好度 45/100
microsoft/TypeScript-Website-Localizations#138 · 1 条评论 · 1 个 reaction ·
查看 microsoft/TypeScript-Website-Localizations 的全部 Issue
相似的 Issue
-
Complexity: Small P-Feature: Projects page ready for merge team role: back end/devOps role: front end size: 0.25pt
难度 1/5 1-3 小时 新手友好度 88/100
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 67/100
bellingcat/toolkit#905 ·
-
self-care self-care:docs-build-time-investigator
难度 2/5 半天 新手友好度 76/100
githubnext/gh-aw-cao#14191 ·
维护者通常 1 天内回复
-
effort:low impact:medium RAG status: auto-triaged
难度 2/5 1-3 小时 新手友好度 84/100
mastra-ai/mastra#25229 · 2 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 88/100
sugarlabs/musicblocks#8984 ·
维护者通常 1 天内回复