Chrome extension's locales builder.
Chrome-i18n is a tool (a builder) for your apps/extensions' locales. Chrome-i18n lets you easily build a complete database of locales starting from some project files.
For example, to build a database from a unique file (the
monolith mode), you
This will load by default the file named
dictionary.json into the current
directory, and build the classic
_locales directory with all the locales
defined inside the dictionary file.
npm install chrome-i18n -g
According to your configuration, you probably should type the command as root to install it globally.
To show the help, just type
To build a project:
chrome-i18nchrome-i18n --file dict.jsonchrome-i18n --file meta.json
As you can see, the only useful parameter you can use is
--file. When omitted,
this parameter will be set by default to
The only supported file format is JSON. Files not conforming to this format will be ignored.
Currently are supported three different formats to define a project:
metadescriptor and the whole
database. See the file
doc/monolith.mdfor further informations about the monolith mode.
doc/category.mdfor further informations about the category mode.
doc/language.mdfor further informations about the language mode.
Currently, people manually manage locales project sources. Every language with its own directory and definition file, all pretty the similiar but the translated message. It's a lot of useless redundancy to manage by hand. This sucks and the goal is to make it much easier.
Chrome-i18n is a specific tool which will build a complete database for your Chrome extensions and web apps starting from some project files, easier to maintain and manage.
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using grunt.
See the CHANGELOG.md file distributed with the project.
Copyright (c) 2012-2013 Marco Trulla - Licensed under the MIT license.
See the LICENSE-MIT file distributed with the project.