1- # fluent- dom
1+ # @ fluent/ dom
22
3- ` fluent- dom ` provides DOM bindings for Project Fluent, a localization
3+ ` @ fluent/ dom` provides DOM bindings for Project Fluent, a localization
44framework designed to unleash the expressive power of the natural language.
55
66## Installation
77
8- ` fluent- dom ` can be used both on the client-side and the server-side. You
8+ ` @ fluent/ dom` can be used both on the client-side and the server-side. You
99can install it from the npm registry or use it as a standalone script (as the
1010` FluentDOM ` global).
1111
12- npm install fluent- dom
12+ npm install @ fluent/ dom
1313
1414
1515## How to use
1616
1717The ` DOMLocalization ` constructor provides the core functionality of
1818full-fallback ready message formatting. It uses a lazy-resolved
19- ` FluentBundle ` objects from the ` fluent ` package to format messages.
19+ ` FluentBundle ` objects from the ` @ fluent/bundle ` package to format messages.
2020
2121On top of that, ` DOMLocalization ` can localize any DOMFragment by
2222identifying localizable elements with ` data-l10n-id ` and translating them.
2323
2424``` javascript
25- import { DOMLocalization } from ' fluent- dom'
25+ import { DOMLocalization } from ' @ fluent/ dom'
2626
2727const l10n = new DOMLocalization (MutationObserver , [
2828 ' /browser/main.ftl' ,
@@ -45,7 +45,7 @@ For imperative uses straight from the JS code, there's also a `Localization`
4545class that provides just the API needed to format messages in the running code.
4646
4747``` javascript
48- import { Localization } from ' fluent- dom'
48+ import { Localization } from ' @ fluent/ dom'
4949
5050function * generateBundles () {
5151 // Some lazy logic for yielding FluentBundles.
0 commit comments