i18n_overview
I18N Comparsion
Section titled “I18N Comparsion”Criteria
Section titled “Criteria”- Complex plural support
- Localized number and date formatting
- ICU Message Format (opens in a new tab) support (?)
- light weight
- support for package concept
- on runtime language detection
- one translation file per language / page
- active development / community
- license
Overview
Section titled “Overview”Out of focus
Section titled “Out of focus”- Globalize
- jQuery.I18n
- vue-i18n
- i18n-js
- Jed (gettext style)
- FBT
- Fluent
- Lisan
- ttag
- schummar-translate
- Rosetta
- Talkr
- Nano Stores I18n
Details
Section titled “Details”i18next
Section titled “i18next”- most complete i18n solution with many third-party plugins (https://www.i18next.com/overview/plugins-and-utils (opens in a new tab))
- support / first-party integration for a wide range of frameworks, e.g. react-i18n (opens in a new tab)
- support for translation file loading and user language detection
- support for interpolation, nesting, plurals, context, gender, built-in formatting functions (Date, Number, Currency, Units..) based on the Intl API (opens in a new tab).
- can be complicated if using more than basic features
- JSON Format (opens in a new tab) for messages
- well established community
FormatJS
Section titled “FormatJS”- first-party React integration, react-intl (opens in a new tab)
- first-class ICU Message Format support
- no build-in translation file loading and user language detection
- good tooling (CLI (opens in a new tab),eslint-plugin (opens in a new tab),…)
- good TMS integration (opens in a new tab)
- support for pre-compiled messages (opens in a new tab) into AST, reduced react-intl without parser (40% smaller)
- react-intl: Internationalizing can be applied only in view layer such as React.Component -> react-intl-universal (opens in a new tab) for Vanilla JS
- well established community
Polyglot
Section titled “Polyglot”- light weight with minimum feature set
- simple solutions for translation, interpolation and pluralization
- no external dependencies
- support for nested phrase objects
- React integration with Wrapper (opens in a new tab)
LinguiJS
Section titled “LinguiJS”- small, robust, intuitive syntax
- support for interpolation, plurals, date/number formats
- uses ICU message format
- CLI for extracting messages
- no build-in translation loader
- support for JS and React
- newer smaller community, but active and helpful
- well documented
- TypeScript support
- monorepo support
eo-locale
Section titled “eo-locale”- support for Vanilla JS and React
- really tiny, but small documentation, too
- message format strictly implemented by ICU standards
- TypeScript support
- optimized for tree shaking
- built with hooks and functional components only
- support for dates, nummeric values and plurals
- nested support
messageformat
Section titled “messageformat”- collection of packages for
- transpile MessageFormat strings to JS functions
- loader for JSON, YAML & .properties message files
- parser for MessageFormat strings to AST
- supporting date and number formatting
- React hooks
- rollup-plugin
typesafe-i18n
Section titled “typesafe-i18n”- fully type-safe and lightweight internationalization library for all your TypeScript and JavaScript projects
- lightweight and easy to use
- support for plurals, switch-case statements, number and date formatting
- locale-detection
- optimized for performance
- generator for boilerplate code
- official Vite support removed since 5.0 but https://stackoverflow.com/questions/72033015/how-to-integrate-typesafe-i18n-with-vite-bundler (opens in a new tab)
https://github.com/jpomykala/awesome-i18n (opens in a new tab)
https://bestofjs.org/projects?tags=i18n (opens in a new tab)
https://dev.to/adrai/i18n-in-the-multiverse-of-formats-1nip (opens in a new tab)
https://phrase.com/blog/posts/the-best-javascript-i18n-libraries/ (opens in a new tab)
https://phrase.com/blog/posts/localizing-javascript-react-apps-with-linguijs/ (opens in a new tab)