5

Github GitHub - ethereum/ethereum-org-website: Ethereum.org is a primary online...

 3 years ago
source link: https://github.com/ethereum/ethereum-org-website
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client
ethereum/ethereum-org-website: Ethereum.org is a primary online resource for the Ethereum community.

How to prepare your content for translation depends on whether you're working on a simple Markdown/MDX page or a React component page.

- MDX pages (/src/content/page/)

Markdown will be translated as whole pages of content, so no specific action is required. Simply create a new folder within /src/content/ with the name of the page, then place index markdown file (ie. index.md) within new folder.

- React component page

English text should be placed into /src/intl/en/page-CORRESPONDING-PAGE.json

Crowdin is the platform we use to manage & crowdsource translation efforts. Please use the following conventions to help streamline this process.

Use kebab casing (utilizing-dashes-between-words) for file names and JSON keys

Use standard sentence casing for entry values

Please avoid embedding links within a sentence. For a word/phrase to be a link, it requires a key/string in the intl JSON. If this is in the middle of another sentence, this results in the sentence being broken into multiple pieces, and requires coding the sentence structure into the JavaScript.

  • This results in significant challenges during translation process, as written syntax for each language will very in terms of ordering subjects/verbs/etc.
  • If you're wanting to link to something within your sentence, create a link at the end of the sentence or paragraph:
<p>All Ethereum transactions require a fee, known as Gas, that gets paid to the miner. <Link to="link">More on Gas</Link></p>

Once, you've addded your English content to the appropriate JSON file, the above code should look something more like:

 <p><Translation id="page-transactions" />{" "}<Link to="link"><Translation id="page-transactions-gas-link" /></Link></p>
  • tl;dr Each individual JSON entry should be a complete phrase by itself

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK