1.0.0 • Published 5 days ago

i18n-pipe v1.0.0

Weekly downloads
16
License
MIT
Repository
-
Last release
5 days ago

i18n pipe

This is a translation library for pipe separated translation strings such as "|en|Hi, my name is Matteo|it|Ciao, il mio nome è Matteo"

How to install

npm i i18n-pipe

How to import

import i18n from 'i18n-pipe';

How to use

get current language

i18n.language(); // returns 'en'

set current language

i18n.language('it'); // returns 'it'

translate a string

i18n.t("|en|Hi, my name is Matteo|it|Ciao, il mio nome è Matteo");
// returns "Ciao, il mio nome è Matteo"
1.0.0

5 days ago

1.0.0-alpha.3

5 days ago

1.0.0-alpha.2

5 days ago

1.0.0-alpha.1

5 days ago

0.0.3

5 years ago

0.0.2

6 years ago

0.0.1

6 years ago

0.1.0

7 years ago