Giter Club home page Giter Club logo

qmk.fm's Introduction

How to add translations of the qmk.fm website

Each language should have its own folder in _i18n/, named using the ISO 639-1 language code, followed by - and the country code where relevant. A list of common ones can be found here.

Permalinks should be generated automatically from the filename, but need to be set manually for index.md pages. The lang variable should be set on all pages. Both of these, along with title (used in <title> in the head, and other metadata) are examplified in the front matter (put at the top of the file) here:

---
title: "QMK固件"
permalink: /zh-cn/
lang: "zh-cn"
---

A summary.md is needed to render the sidebar content - _includes/en_sidebar.md should be used as the template. Links should be relativised with the language preceding it: /zh-cn/support.

The _data/strings.yml file also needs to have an entry for the language:

  zh-cn: &DEFAULT_ZH_CN
    <<: *DEFAULT_EN
    language_name: "中文"
    language: "官话"
    qmk_firmware: "QMK固件"

The <<: *DEFAULT_EN allows zh-cn to inherit all values from the English entry, and the keys following it override those. It's recommended to translate all entries for full coverage.

qmk.fm's People

Contributors

dependabot[bot] avatar drashna avatar duckle29 avatar ezuk avatar germ avatar itsaferbie avatar jackhumbert avatar mkem114 avatar noroadsleft avatar npoirey avatar olivia avatar qmk-bot avatar skullydazed avatar technomancy avatar yanfali avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.