Internationalization is the design and development of a product, application, or service that enables easy localization for audiences that vary in culture, region, or language. Internationalization is often written as i18n, where 18 is the number of letters between i and n in the English word.
Localization is the adaptation of your product, application, or service to the cultural, legal, and other requirements of a specific language, country, or population. Localization is more than just translation of the user interface—it also includes customization related to:
- Number formats, including date and time, phone numbers, duration, currency, and units of measure
- Bi-directional display
- Symbols, icons, and colors
- Text and graphics
- Local regulations
- Legal requirements
Like internationalization, localization has a short form. It's often written as l10n, where 10 is the number of letters between l and n.
What is the difference between i18n and l10n?
Internationalization lays the foundation for easy localization. In other words, internationalization is the architecture and platform and localization is the data.
Why are we localizing Kibana?
As Elastic continues to grow, we have more and more customers who are not native English speakers. Localizing Kibana helps us better serve our users in countries such as China and Germany.
Challenges of localization
Localizing an application requires a tremendous amount of information, consideration, and effort. Every language has different rules and conventions, and adapting to them can be tricky.
Localizing Kibana is even more challenging because it relies on several UI frameworks (React and Angular) and requires localization in different environments (browser and NodeJS).
Popular i18n and i10n frameworks
- React-intl. This library provides React components and an API to format dates, numbers, and strings, including pluralization and handling translations. It's an open-source project from Yahoo, and part of Format.js.
- i18next. This internationalization framework works in browser and NodeJS, providing plugins for many UI frameworks, including React and Angular.
- Fluent.js. This modern internationalization framework is built around the latest web platform technologies and custom FTL message format that work in browser and NodeJS.
Deciding which framework to use
In addition to common localization considerations such as default message support, easy message extraction, rich pluralization format, and good syntax ergonomic, we also took into account these aspects specific to Kibana.
- The localization framework must be UI framework agnostic and easily consumable in all parts of Kibana because Angular and React co-live in Kibana.
- The localization framework must support Node.js server-side generated content.
The following table shows the evaluation of the six frameworks against our requirements.
There is no perfect framework that meets all requirements. In deciding which framework to use, we had to balance the out-of-the-box features with the stability, flexibility, and priority of the requirements. We also had to consider our users and contributors to make sure they are continuously supported,
As a result, we decided to move forward with the solution based on the FormatJS core libs. We based our decision on the following:
- It has a relatively small code base and good documentation
- It uses well-known ICU message syntax
- It can be used on the server side (Node.JS), in React (react-intl) and AngularJS (a custom component that we'll build).
You can implement localization in almost any framework. We encourage you to analyze your business scenarios, and then search and find the best option for your application.