Skip to content
This repository has been archived by the owner on Nov 1, 2020. It is now read-only.

Localization

jason-sanjose edited this page Aug 24, 2012 · 6 revisions

TL;DR

Using Localized Strings

The snippets below show how to use localized strings in core Brackets code.

In JavaScript

var Strings = require("strings"); // load the Strings module
...
$("<span/>").text(Strings.CMD_ABOUT); // insert a localized string

In an HTML template

<!-- templateContent.html -->
<span>{{CMD_ABOUT}}</span>

/* JavaScript */
var Strings = require("strings"),
    templateContent = require("text!templateContent.html"); // load text content of template file

var html = Mustache.render(templateContent, Strings); // use Mustache to insert translated strings

Creating New Translations

Creating new translations

Localizing Extensions

Example: Localized Extension README.MD

Implementation Details

TODO

Clone this wiki locally