1.0.0 • Published 6 months ago

i18next-subliminal v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
6 months ago

Introduction

Actions npm version

This package helps to pass meta information via invisible characters for the shown translation resources.

Getting started

Source can be loaded via npm.

# npm package
$ npm install i18next-subliminal

Wiring up as i18next plugin:

import i18next from 'i18next'
import { PostProcessor } from 'i18next-subliminal'

i18next.use(PostProcessor).init({
  postProcess: 'subliminal',
  postProcessPassResolved: true,
})

standalone usage:

import { wrap, unwrap, containsHiddenMeta } from 'i18next-subliminal'

const wrapped = wrap('my text', { key: 'my.key', ns: 'my-ns', lng: 'en', source: 'translation' })

const unwrapped = unwrap(wrapped)
unwrapped.text // 'my text'
unwrapped.invisibleMeta // { key: 'my.key', ns: 'my-ns', lng: 'en', source: 'translation' }

containsHiddenMeta(wrapped) // true


From the creators of i18next: localization as a service - locize.com

A translation management system built around the i18next ecosystem - locize.com.

locize

With using locize you directly support the future of i18next.


1.0.0

6 months ago

0.0.4

6 months ago

0.0.3

7 months ago

0.0.2

7 months ago

0.0.1

7 months ago