/js-lingui

Seamless i18n in Javascript and React

Primary LanguageJavaScriptMIT LicenseMIT

jsLingui

I18n libraries for JavaScript focused on high quality developer experience


Buy Me A Coffee

CircleCI AppVeyor Code Coverage PRs Welcome All Contributors Watch on GitHub Star on GitHub Tweet

Internationalization is the design and development of a product, application or document content that enables easy localization for target audiences that vary in culture, region, or language.

--- W3C Web Internationalization FAQ

jsLingui simplifies internationalization in JavaScript. It covers all i18n features while keeping library size small by using compiled message catalogs. Messages are automatically extracted from source and compiled at build step which makes production code small and fast.

Optional but recommended are Babel plugins for auto-generating messages in ICU MessageFormat from tagged template literals (plain JavaScript) or React components.

Example use case with React

Features

  • Lightweight - about 5kb gzipped (1.9 kB core, 3.1 kB React components)
  • Full support of ICU MessageFormat with extension to support HTML
  • Unopinionated - supports manual and auto-generated message IDs out-of-the-box
  • Batteries included - CLI for working with message catalogs (extracting, validating, compiling, …)
  • Easy to migrate from react-intl

Quickstart

Checkout these tutorials for installation instructions and brief introduction:

If you're a react-intl user, checkout comparison of react-intl and jsLingui.

Support

If you are having issues, please let us know.

  • Join us at gitter.im to get almost instant feedback.
  • Ask question on StackOverflow and mark it with jsLingui tag.
  • If something doesn't work as documented, documentation is missing or if you just want to suggest a new feature, create an issue.

Contribute

Contribution to open-source project is everything from spreading a word, writing documentation to implementing features and fixing bugs.

  • Do you use jsLingui in production site? Let us know!
  • Have you seen interesting talk or article about i18n? Share it!
  • Have you found a bug or do you want to suggest a new feature? Create an issue!
  • Do you want to improve the docs and write some code? Read the contributors guide and send a PR!

Big thanks goes to these people (emoji key):


TomΓ‘Ε‘ Ehrlich

πŸ’» πŸ“– πŸ’‘ βœ…

Josef Hornych

πŸ“– πŸ›

Christian Kaps

πŸ›

brunesto

πŸ’» πŸ›

David Furlong

πŸ’¬

Thibaut

πŸ› πŸ“–

Sebastian SobociΕ„ski

πŸ’»

Matt Labrum

πŸ“–

Vincent Ricard

πŸ“–

Adam Gruber

πŸ’»

Spencer Mefford

πŸ’»

Jeow Li Huan

πŸ’»

Vojtech Novak

πŸ“–

This project follows the all-contributors specification.

License

The project is licensed under the MIT license.