File tree Expand file tree Collapse file tree 2 files changed +31
-1
lines changed
Expand file tree Collapse file tree 2 files changed +31
-1
lines changed Original file line number Diff line number Diff line change 11# Changelog
22
3+ ## @fluent/react 0.13.0 (July 2, 2020)
4+
5+ - Add the ` useLocalization ` hook. (#467 , #475 )
6+
7+ The hook can be used to get a reference to the current
8+ ` ReactLocalization ` instance, for example in order to format a
9+ translation with the imperative ` getString ` API.
10+
11+ ``` js
12+ let {l10n} = useLocalization ();
13+ alert (l10n .getString (" hello" ));
14+ ```
15+
16+ - Remove ` compat.js` builds and compile everything to ES2018 . (#472 )
17+
18+ TypeScript source code is now compiled to ES2018 files in the ` esm/`
19+ directory . These files are then bundled into a single ` index.js` UMD file
20+ without any further transpilation.
21+
22+ The ` compat.js` build (available as ` @fluent/bundle/compat` ) was removed.
23+ Please use your own transpilation pipeline if ES2018 is too recent for
24+ your project.
25+
26+ Refer to https: // github.com/projectfluent/fluent.js/wiki/Compatibility
27+ for more information.
28+
29+ - Require ` @fluent/bundle` 0.16 .0 as peer dependency.
30+
31+ In ` @fluent/bundle` 0.16 .0 ` FluentArgument` was renamed to ` FluentVariable` .
32+
333## @fluent/ react 0.12 .0 (April 7 , 2020 )
434
535 - Migrate to TypeScript. (#458 )
Original file line number Diff line number Diff line change 11{
22 "name" : " @fluent/react" ,
33 "description" : " Fluent bindings for React" ,
4- "version" : " 0.12 .0" ,
4+ "version" : " 0.13 .0" ,
55 "homepage" : " https://projectfluent.org" ,
66 "author" : " Mozilla <l10n-drivers@mozilla.org>" ,
77 "license" : " Apache-2.0" ,
You can’t perform that action at this time.
0 commit comments