-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathI18n.js
75 lines (71 loc) · 1.56 KB
/
I18n.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
import { createI18n } from '../lib';
const locales = ['en', 'fr', 'pig'];
const translations = {
en: {
home: 'Home',
about: 'About',
topics: 'Topics',
homePage: {
title: 'Home',
text: 'This is the homepage',
},
aboutPage: {
title: 'About',
text: 'About the project',
},
topicPage: {
select: 'Please select a topic',
components: 'Components',
},
rendering: 'rendering',
components: 'components',
props_v_state: 'props-v-state',
},
fr: {
home: 'Accueil',
about: 'À propos',
topics: 'Sujets',
homePage: {
title: 'Accueil',
text: "Ceci est la page d'accueil",
},
aboutPage: {
title: 'À propos',
text: 'À propos du sujet',
},
topicPage: {
select: 'Choisissez un sujet',
rendering: 'Rendu avec React',
components: 'Composants',
},
rendering: 'rendu',
components: 'composants',
props_v_state: 'accessoires-v-etat',
},
pig: {
home: 'Eomehay',
about: 'Boutaay',
topics: 'Opicstay',
homePage: {
title: 'Omehay',
text: 'Histay siay hetay omehay agepay',
},
aboutPage: {
title: 'Boutaay',
text: 'Boutaay hetay rojectpay',
},
topicPage: {
select: 'Leasepay electsay aay opictay',
rendering: 'Enderedray ithway React',
components: 'Omponentscay',
},
rendering: 'enderingray',
components: 'omponentscay',
props_v_state: 'ropspay-vay-tatesay',
},
};
const I18n = createI18n(
locales,
translations,
);
export default I18n;