3.0.1 • Published 1 year ago

translocalizer v3.0.1

Weekly downloads
2
License
MIT
Repository
github
Last release
1 year ago

Translocalizer

Travis Version Issues License Dependencies

Translocalizer is a tool for localizing your application in seconds.

Available Languages

Translocalizer uses Yandex Translate under the hood, so check this page for the list of available languages.

Installation

Yarn:

$ yarn add -D translocalizer

NPM:

$ npm install -D translocalizer

Usage

To use Translocalizer, you will need a Yandex Translate API key, which you can obtain here. Create a new key for every project since using a certain key too many times in succession can lead to rate limiting.

Using the CLI

// translocalizer.json

{
  "basePath": "i18n",
  "srcFile": "en.json",
  "filenameTemplate": "*.json",
  "languages": ["fr", "it"],
  "apiKey": "trnsl.1.1..."
}
$ translocalizer [options]

To see all available options, run this command:

$ translocalizer --help

Using the API

import { Translocalizer } from "translocalizer";

const config = {
  basePath: "i18n",
  srcFile: "en.json",
  filenameTemplate: "*.json",
  languages: ["fr", "it"],
  apiKey: "trnsl.1.1..."
};

Translocalizer.localize(config);
3.0.1

1 year ago

3.0.0

1 year ago

2.1.0

1 year ago

2.0.1

1 year ago

2.0.0

1 year ago

1.2.0

1 year ago

1.1.1

1 year ago

1.1.0

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago