# @fluent/react

> Fluent bindings for React

Latest version **0.15.2** (published 2023-08-01) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @fluent/react
pnpm add @fluent/react
yarn add @fluent/react
bun add @fluent/react
```

## Health

**Score 40/100 (D)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; pre 1.0.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 0.15.2 |
| Published | 2023-08-01 |
| First published | 2019-07-25 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=14.0.0 |
| Dependencies | 2 |
| Unpacked size | 60.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1010 |
| Author | Mozilla |
| Maintainers | eemeli, zbraniecki, tatumcreative, flod |
| Keywords | localization, l10n, internationalization, i18n, ftl, plural, gender, locale, language, formatting, translate, translation, format, parser, react, reactjs |

## Links

- npm: https://www.npmjs.com/package/@fluent/react
- Repository: https://github.com/projectfluent/fluent.js
- Homepage: https://projectfluent.org
- Issues: https://github.com/projectfluent/fluent.js/issues
- npm.io page: https://npm.io/package/@fluent/react

## Dependencies (2)

- [cached-iterable](https://npm.io/package/cached-iterable.md) ^0.3.0
- [@fluent/sequence](https://npm.io/package/@fluent/sequence.md) ^0.8.0

## Alternatives

- [messageformat](https://npm.io/package/messageformat.md) — 329.7K weekly downloads
- [@mintlify/scraping](https://npm.io/package/@mintlify/scraping.md) — 294.8K weekly downloads
- [@mintlify/previewing](https://npm.io/package/@mintlify/previewing.md) — 209.5K weekly downloads
- [@mintlify/prebuild](https://npm.io/package/@mintlify/prebuild.md) — 209.5K weekly downloads
- [@mintlify/link-rot](https://npm.io/package/@mintlify/link-rot.md) — 206.3K weekly downloads

## Recent versions

- 0.15.2 (latest) — 2023-08-01
- 0.15.1 — 2023-05-27
- 0.15.0 — 2023-03-13
- 0.14.1 — 2021-12-21
- 0.14.0 — 2021-09-13
- 0.13.1 — 2021-04-07
- 0.13.0 — 2020-07-02
- 0.12.0 — 2020-04-07
- 0.11.1 — 2020-01-31
- 0.11.0 — 2020-01-23
- 0.10.0 — 2019-07-30
- 0.9.0 — 2019-07-25

## README

# @fluent/react ![](https://github.com/projectfluent/fluent.js/workflows/test/badge.svg)

`@fluent/react` provides the React bindings for [Project Fluent][].

[project fluent]: https://projectfluent.org

## Installation

`@fluent/react` can be used both on the client-side and the server-side. You
can install it from the npm registry or use it as a standalone script (as the
`FluentReact` global).

    npm install @fluent/react

# Integrating with React apps

`@fluent/react` takes advantage of React's Components system and the virtual
DOM. Translations are exposed to components via the _provider_ pattern.

There are many approaches to fetching and storing translations. To allow
maximum flexibility, `@fluent/react` expects the developer to write a little
bit of a setup code related to language negotiation and translation fetching.
It makes `@fluent/react` unopinionated and suitable for many different
scenarios. You will likely also need to install a few other packages:
`@fluent/bundle`, `@fluent/langneg` and `intl-pluralrules`.

Consult the [wiki][] for documentation on how to set up and use
`@fluent/react`.

The API reference is available at https://projectfluent.org/fluent.js/react.

[wiki]: https://github.com/projectfluent/fluent.js/wiki/React-Bindings

---
_Source: https://npm.io/package/@fluent/react · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
