# formatjs/formatjs

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/formatjs-formatjs).**

14,680 stars · 1,374 forks · TypeScript

## Links

- GitHub: https://github.com/formatjs/formatjs
- Homepage: https://formatjs.github.io/
- awesome-repositories: https://awesome-repositories.com/repository/formatjs-formatjs.md

## Topics

`formatjs` `globalization` `i18n` `internationalization` `intl` `javascript` `localization` `react` `translation` `ui` `web`

## Description

FormatJS is an internationalization framework and library designed for building web applications that support multiple languages and regional formats. It provides a comprehensive suite of tools for managing the translation workflow, including the extraction of translatable strings from source code and the compilation of human-readable templates into optimized JavaScript functions.

The project distinguishes itself by implementing the ICU MessageFormat standard, which enables the handling of complex linguistic requirements such as pluralization and gender-based text variations. By utilizing a build-time utility to transform translation files into machine-ready formats, it ensures that localized content is loaded and displayed efficiently within the application rendering lifecycle.

Beyond core translation management, the library facilitates the formatting of dates, numbers, and currencies by leveraging standardized internationalization APIs. This allows developers to present data in accordance with specific cultural and regional expectations, maintaining consistent messaging across diverse locales.

The project provides a command-line interface to automate the extraction and compilation of translation messages during the build process. It is designed to operate with minimal external dependencies, ensuring compatibility across various browser and server-side JavaScript environments.

## Tags

### Software Engineering & Architecture

- [Internationalization Frameworks](https://awesome-repositories.com/f/software-engineering-architecture/internationalization-frameworks.md) — Acts as a core internationalization framework for managing translation files and locale-specific data formatting.
- [Pluralization Rules](https://awesome-repositories.com/f/software-engineering-architecture/localization/pluralization-rules.md) — Implements pluralization rules to select correct grammatical forms based on numeric values and locale-specific data.
- [Locale Translation Files](https://awesome-repositories.com/f/software-engineering-architecture/application-lifecycle-management/configuration-management/configuration-formats-and-schemas/yaml-configuration-files/locale-translation-files.md) — Automates the compilation of translation files into machine-ready formats during the build process. ([source](https://formatjs.github.io/docs/getting-started/installation))

### Web Development

- [Web Application Frameworks](https://awesome-repositories.com/f/web-development/web-application-frameworks.md) — Provides a comprehensive framework for building web applications that support multiple languages and regional formats.
- [Message Format Libraries](https://awesome-repositories.com/f/web-development/javascript-utility-libraries/message-format-libraries.md) — Implements ICU MessageFormat standards to handle complex linguistic requirements like pluralization and gender variations.
- [Internationalized Date Formatting](https://awesome-repositories.com/f/web-development/internationalized-date-formatting.md) — Provides locale-aware formatting for dates, numbers, and currencies using standardized internationalization APIs.
- [Date and Time Formatting](https://awesome-repositories.com/f/web-development/date-and-time-formatting.md) — Displays dates, times, and currency values according to specific cultural and regional expectations.
- [Localization Services](https://awesome-repositories.com/f/web-development/internationalization-localization/translation-management-platforms/localization-services.md) — Manages the end-to-end workflow of compiling and loading localized text within web applications.

### Content Management & Publishing

- [Translation Management](https://awesome-repositories.com/f/content-management-publishing/content-management-systems/translation-management.md) — Streamlines the extraction, translation, and injection of localized strings into web application interfaces.
- [Source Code Extractors](https://awesome-repositories.com/f/content-management-publishing/content-management-systems/translation-management/xliff-extraction-and-compilation/source-code-extractors.md) — Automates the identification and extraction of translatable strings from source code during the build process.

### Development Tools & Productivity

- [Translation Tools](https://awesome-repositories.com/f/development-tools-productivity/translation-tools.md) — Provides build-time utilities to transform translation files into optimized formats for localized environments.
- [Template Compilation Tools](https://awesome-repositories.com/f/development-tools-productivity/build-tooling/template-compilation-tools/template-compilation-tools.md) — Compiles human-readable translation templates into optimized JavaScript functions for efficient runtime execution.

### User Interface & Experience

- [Internationalized Content Renderers](https://awesome-repositories.com/f/user-interface-experience/content-formatting/internationalized-content-renderers.md) — Formats dates, numbers, and strings into locale-specific representations to match regional user expectations. ([source](https://formatjs.github.io/docs/getting-started/installation))
