0.0.3 • Published 5 years ago

lingui-phraseapp v0.0.3

Weekly downloads
5
License
ISC
Repository
github
Last release
5 years ago

lingui-phraseapp

This is a package which helps you to use lingui together with PhraseApp In-Context Editor

Installation

npm install lingui-phraseapp

Usage

You need to init the Editor and transform your catalogue to proper format. For that you have initializePhraseAppEditor(config) and transformCatalog(catalog, config) functions.

import { initializePhraseAppEditor, transformCatalog } from 'lingui-phrase';
import catalog from "./locales/en/messages";

const config = {
  projectId: "<YOUR_PROJECT_ID>",
  autoLowercase: false,
  phraseEnabled: true
};

initializePhraseAppEditor(config);
const catalogInEditorFormat = transformCatalog(catalog, config);
const i18n = setupI18n({ catalogs: catalogInEditorFormat })
...
0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago