react-i18next
TypeScript icon, indicating that this package has built-in type declarations

15.6.0 • Public • Published

react-i18next Tweet

CI Code Climate Coverage Status Quality npm

IMPORTANT:

Master Branch is the newest version using hooks (>= v10).

$ >=v10.0.0
npm i react-i18next

react-native: To use hooks within react-native, you must use react-native v0.59.0 or higher

For the legacy version please use the v9.x.x Branch

$ v9.0.10 (legacy)
npm i react-i18next@legacy

Documentation

The documentation is published on react.i18next.com and PR changes can be supplied here.

The general i18next documentation is published on www.i18next.com and PR changes can be supplied here.

What will my code look like?

Before: Your react code would have looked something like:

...
<div>Just simple content</div>
<div>
  Hello <strong title="this is your name">{name}</strong>, you have {count} unread message(s). <Link to="/msgs">Go to messages</Link>.
</div>
...

After: With the trans component just change it to:

...
<div>{t('simpleContent')}</div>
<Trans i18nKey="userMessagesUnread" count={count}>
  Hello <strong title={t('nameTitle')}>{{name}}</strong>, you have {{count}} unread message. <Link to="/msgs">Go to messages</Link>.
</Trans>
...

📖 What others say

Why i18next?

  • Simplicity: no need to change your webpack configuration or add additional babel transpilers, just use create-react-app and go.
  • Production ready we know there are more needs for production than just doing i18n on the clientside, so we offer wider support on serverside too (nodejs, php, ruby, .net, ...). Learn once - translate everywhere.
  • Beyond i18n comes with locize bridging the gap between development and translations - covering the whole translation process.

ecosystem

Localization workflow

Want to learn more about how seamless your internationalization and translation process can be?

video

watch the video

Installation

Source can be loaded via npm or downloaded from this repo.

# npm package
$ npm install react-i18next
  • If you don't use a module loader it will be added to window.reactI18next

Do you like to read a more complete step by step tutorial?

Here you'll find a simple tutorial on how to best use react-i18next. Some basics of i18next and some cool possibilities on how to optimize your localization workflow.

Examples

v9 samples

Requirements

  • react >= 16.8.0
  • react-dom >= 16.8.0
  • react-native >= 0.59.0
  • i18next >= 10.0.0 (typescript users: >=17.0.9)

v9

Core Contributors

Thanks goes to these wonderful people (emoji key):


Jan Mühlemann

💻 💡 👀 📖 💬

Adriano Raiano

💻 💡 👀 📖 💬

Pedro Durek

💻 💡 👀 💬

Tiger Abrodi

💻 👀

This project follows the all-contributors specification. Contributions of any kind are welcome!


Gold Sponsors


localization as a service - locize.com

Needing a translation management? Want to edit your translations with an InContext Editor? Use the original provided to you by the maintainers of i18next!

locize

By using locize you directly support the future of i18next and react-i18next.


Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
15.6.012,634latest
9.0.109,390legacy
10.0.0-alpha.34next

Version History

VersionDownloads (Last 7 Days)Published
15.6.012,634
15.5.3868,356
15.5.2304,372
15.5.1247,341
15.5.0681
15.4.1366,770
15.4.0167,601
15.3.0617
15.2.043,228
15.1.418,066
15.1.321,754
15.1.27,875
15.1.148,987
15.1.037,157
15.0.312,539
15.0.263,511
15.0.188,212
15.0.031,140
14.1.3382,047
14.1.2120,599
14.1.139,385
14.1.092,309
14.0.81,682
14.0.7350
14.0.65
14.0.545,069
14.0.4474
14.0.31,375
14.0.2152,985
14.0.113,630
14.0.020,926
13.5.0460,360
13.4.15,957
13.4.01,475
13.3.28,821
13.3.122,849
13.3.012,153
13.2.231,463
13.2.13,188
13.2.08,139
13.1.27,548
13.1.1631
13.1.088
13.0.315,436
13.0.219,398
13.0.119,283
13.0.05,402
12.3.1338,681
12.3.0156
12.2.236,904
12.2.1355
12.2.055,454
12.1.539,799
12.1.422,301
12.1.32
12.1.223,732
12.1.111,419
12.1.0112
12.0.032,047
11.18.6582,211
11.18.59,002
11.18.414,014
11.18.316,532
11.18.2218
11.18.121,173
11.18.06,114
11.17.43,027
11.17.32,455
11.17.217,197
11.17.17,849
11.17.03,969
11.16.112,757
11.16.10199
11.16.917,198
11.16.81,103
11.16.715,006
11.16.64,286
11.16.51,844
11.16.42,699
11.16.3183
11.16.211,295
11.16.14,637
11.16.014
11.15.71,979
11.15.610,143
11.15.56,578
11.15.46,031
11.15.314,575
11.15.2798
11.15.15,479
11.15.01,954
11.14.324,612
11.14.25,295
11.14.11,613
11.14.0118
11.13.011,505
11.12.026,603
11.11.417,929
11.11.34,773
11.11.2337
11.11.12,159
11.11.07,051
11.10.017,230
11.9.01,888
11.8.1518,740
11.8.1454
11.8.138,246
11.8.129,632
11.8.11118
11.8.106,504
11.8.9681
11.8.83,219
11.8.79,835
11.8.61,519
11.8.513,805
11.8.41,479
11.8.3335
11.8.265
11.8.132
11.8.045
11.7.41,024
11.7.38,456
11.7.27,021
11.7.1251
11.7.011,550
11.6.0280
11.5.1315
11.5.0730
11.4.017,283
11.3.51,600
11.3.45,734
11.3.33,823
11.3.238
11.3.11,376
11.3.0369
11.2.7490
11.2.669
11.2.5534
11.2.428
11.2.32
11.2.2208
11.2.12,460
11.2.02
11.1.0249
11.0.12,321
11.0.067
10.13.226,390
10.13.11,506
10.13.055
10.12.5560
10.12.4108
10.12.3271
10.12.23,219
10.12.198
10.12.08
10.11.557
10.11.45,862
10.11.331
10.11.2310
10.11.135
10.11.0664
10.10.0130
10.9.1140
10.9.0253
10.8.1188
10.8.069
10.7.0414
10.6.2126
10.6.1112
10.6.0110
10.5.3184
10.5.2458
10.5.118
10.5.0258
10.4.26
10.4.110
10.4.01
10.3.18
10.3.052
10.2.17
10.2.089
10.1.212
10.1.10
10.1.01
10.0.538
10.0.4534
10.0.31
10.0.24
10.0.19
10.0.043
10.0.0-alpha.34
10.0.0-alpha.20
10.0.0-alpha.10
9.0.109,390
9.0.98
9.0.80
9.0.70
9.0.68
9.0.54
9.0.425
9.0.30
9.0.2295
9.0.1401
9.0.03
8.4.02,921
8.3.939
8.3.8186
8.3.724
8.3.615
8.3.529
8.3.40
8.3.30
8.3.20
8.3.145
8.3.00
8.2.01
8.1.20
8.1.12
8.1.060
8.0.8200
8.0.7136
8.0.620
8.0.51
8.0.40
8.0.30
8.0.20
8.0.10
8.0.00
7.13.07,595
7.12.037
7.11.1259
7.11.092
7.10.1286
7.10.00
7.9.10
7.9.091
7.8.13
7.8.062
7.7.0120
7.6.12,861
7.6.024
7.5.1122
7.5.020
7.4.0114
7.3.6282
7.3.51
7.3.481
7.3.30
7.3.25
7.3.1125
7.3.03
7.2.070
7.1.1278
7.1.02
7.0.2416
7.0.11
7.0.04
6.2.0105
6.1.00
6.0.6105
6.0.524
6.0.42
6.0.31
6.0.20
6.0.11
6.0.00
5.4.160
5.4.02
5.3.01
5.2.08
5.1.00
5.0.00
4.8.0573
4.7.05
4.6.48
4.6.310
4.6.29
4.6.11
4.6.01
4.5.02
4.4.01
4.3.01
4.2.08
4.1.21
4.1.11
4.1.012
4.0.01
3.1.2478
3.1.16
3.1.052
3.0.03
2.2.3108
2.2.21
2.2.12
2.2.0100
2.1.06
2.0.12
2.0.01
1.11.0132
1.10.1431
1.10.02
1.9.03
1.8.01
1.7.01
1.6.31
1.6.22
1.6.10
1.6.00
1.5.30
1.5.20
1.5.11
1.5.00
1.4.20
1.4.12
1.4.00
1.3.10
1.3.00
1.2.10
1.2.00
1.1.00
1.0.11
1.0.00
0.1.00
0.0.40
0.0.30
0.0.21
0.0.12
0.0.010

Package Sidebar

Install

npm i react-i18next

Weekly Downloads

5,520,563

Version

15.6.0

License

MIT

Unpacked Size

332 kB

Total Files

71

Last publish

Collaborators

  • adrai
  • jamuhl