Title: Translation Recommendations · Issue #21 · microsoft/TypeScript-Website-Localizations · GitHub
Open Graph Title: Translation Recommendations · Issue #21 · microsoft/TypeScript-Website-Localizations
X Title: Translation Recommendations · Issue #21 · microsoft/TypeScript-Website-Localizations
Description: 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 h...
Open Graph Description: 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 uniq...
X Description: 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 uniq...
Opengraph URL: https://github.com/microsoft/TypeScript-Website-Localizations/issues/21
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Translation Recommendations","articleBody":"## How To Contribute\r\n\r\n1. Join the [TypeScript Discord](https://discord.gg/typescript) - come say hi the [`ts-web-translate`](https://discord.gg/gG7nsGA)\r\n\r\n2. Follow the instructions on the README of this repo to get set up.\r\n\r\n\r\n#### All Markdown Docs\r\n\r\nEach 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.\r\n\r\n#### Website\r\n\r\nThe 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\r\n\r\nThere 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.\r\n\r\n#### Playground\r\n\r\nYou can cover the examples in the dropdown in the playground (and in the site footer on desktops.) [Full docs here](https://github.com/microsoft/TypeScript-Website/tree/v2/packages/playground-examples)\r\n\r\n- Make a subfolder with the code of the language [in the copy folder of the 'playground-examples'](https://github.com/microsoft/TypeScript-Website/tree/v2/packages/playground-examples)\r\n- Ensure the _filename_ are the same as English, (you can provide a different title via the JSON headers in the ts/js files) \r\n- [Check out this folder](https://github.com/microsoft/TypeScript-Website/tree/v2/packages/tsconfig-reference/)\r\n- Ensure the _filename_ is the same (we can provide a different title via the YML headers in the markdown files) \r\n\r\n---\r\n\r\n## Recommendations\r\n\r\nI'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.\r\n\r\n#### Translate code to be a cultural fit. E.g.\r\n\r\n```ts\r\nconst helloWorld = \"Hi\" \r\n``` \r\n\r\nto\r\n\r\n```ts\r\nconst olaMundo = \"Olá`\r\n```\r\n\r\n#### Translate names in example \r\n\r\n```ts\r\nconst user = { name: \"John\" }\r\n``` \r\n\r\nto\r\n\r\n```ts\r\nconst usar = { name: \"João\" }\r\n```\r\n\r\nNote: 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.\r\n\r\n#### Translate Technical Terms, but keep English around\r\n\r\nThis one is nuanced, but a term like `Mapped Type` is _the name_ for this:\r\n\r\n```ts\r\ntype MyPartialType\u003cType> = {\r\n // For every existing property inside the type of Type\r\n // convert it to be a ?: version\r\n [Property in keyof Type]?: Type[Property];\r\n};\r\n```\r\n\r\nSo, 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.","author":{"url":"https://github.com/orta","@type":"Person","name":"orta"},"datePublished":"2021-02-01T09:31:40Z","url":"https://github.com/microsoft/TypeScript-Website-Localizations/issues/21"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:7152b02f-1b2b-4b38-ce9e-ccbdc1682edf |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E92A:2D2F2F:2F74DF6:3C90B4C:6B01B6F8 |
| html-safe-nonce | d9fe53ff6d484bc653f72a0b6da15da184804411dea3924ee58884559eb3fa65 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFOTJBOjJEMkYyRjoyRjc0REY2OjNDOTBCNEM6NkIwMUI2RjgiLCJ2aXNpdG9yX2lkIjoiNjEyODczMjA5OTExMDM1MjYzMiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 549f25257ab541c4ef8481b0d60f4c03dd0447478683d73916c1c161d44d155a |
| hovercard-subject-tag | issue:798160871 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/microsoft/TypeScript-Website-Localizations/21/issue_layout |
| twitter:image | https://opengraph.githubassets.com/923ed0a15e7edf490b4ac1335822a33cc210cac61ac30550ab1a7d2ec404d29d/microsoft/TypeScript-Website-Localizations/issues/21 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/923ed0a15e7edf490b4ac1335822a33cc210cac61ac30550ab1a7d2ec404d29d/microsoft/TypeScript-Website-Localizations/issues/21 |
| og:image:alt | 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 uniq... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | orta |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/microsoft/TypeScript-Website-Localizations git https://github.com/microsoft/TypeScript-Website-Localizations.git |
| octolytics-dimension-user_id | 6154722 |
| octolytics-dimension-user_login | microsoft |
| octolytics-dimension-repository_id | 326764681 |
| octolytics-dimension-repository_nwo | microsoft/TypeScript-Website-Localizations |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 326764681 |
| octolytics-dimension-repository_network_root_nwo | microsoft/TypeScript-Website-Localizations |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width