6.36.0 • Published 5 months ago

@talend/locales-tui v6.36.0

Weekly downloads
813
License
Apache-2.0
Repository
github
Last release
5 months ago

TUI locales

This module contains i18n files for TUI project.

How to install

yarn add @talend/locales-tui 

or

npm install @talend/locales-tui

How to use with i18next

Synchronous use

i18n.js

import i18n from 'i18next';

import merge from 'lodash/merge';

import { namespaces as tuiNamespaces } from '@talend/locales-tui/namespaces';
import { locales as tuiLocales } from '@talend/locales-tui/locales';

i18n
	.init({
		ns: [
			...tuiNamespaces,
			...myProjectNamespaces
		],
		resources: merge(tuiLocales, myProjectLocales),
	});

export default i18n;

Asynchronous use

For async load, you need to copy the i18n files to the location you want to serve them

webpack.config.js

const CopyWebpackPlugin = require('copy-webpack-plugin');

module.exports = {
	plugins: [
		new CopyWebpackPlugin([
			{ from: 'node_modules/@talend/locales-tui/locales', to: 'assets/locales' },
		]),
	]
}

i18n.js

import i18n from 'i18next';
import XHR from 'i18next-xhr-backend';

import { namespaces as tuiNamespaces } from '@talend/locales-tui/namespaces';

i18n
	.use(XHR)
	.init({
		ns: [
			...tuiNamespaces,
			...myProjectNamespaces
		],
		backend: {
			loadPath: '/assets/locales/{{lng}}/{{ns}}.json',
		},
	});

export default i18n;
6.36.0

5 months ago

6.31.0

7 months ago

6.24.0

9 months ago

6.19.0

9 months ago

6.17.0

10 months ago

6.16.0

10 months ago

6.15.0

11 months ago

6.14.0

11 months ago

6.12.0

11 months ago

6.11.0

12 months ago

6.9.0

12 months ago

6.5.0

1 year ago

5.29.0

1 year ago

5.26.0

1 year ago

5.23.0

1 year ago

5.24.0

1 year ago

5.21.0

1 year ago

5.20.0

1 year ago

5.19.0

1 year ago

5.18.0

1 year ago

5.16.0

1 year ago

5.17.0

1 year ago

5.14.0

1 year ago

5.13.0

2 years ago

5.12.0

2 years ago

5.11.1

2 years ago

5.11.0

2 years ago

5.9.0

2 years ago

5.8.0

2 years ago

5.6.0

2 years ago

5.5.0

2 years ago

5.4.0

2 years ago

5.3.0

2 years ago

4.38.2

2 years ago

5.2.1

2 years ago

4.38.1

2 years ago

5.2.0

2 years ago

5.1.1

2 years ago

5.0.0

2 years ago

4.37.1

2 years ago

4.37.0

2 years ago

4.36.1

2 years ago

4.36.0

2 years ago

4.35.0

2 years ago

4.34.0

2 years ago

4.32.0

2 years ago

4.31.0

2 years ago

4.30.1

2 years ago

4.29.1

2 years ago

4.30.0

2 years ago

4.29.0

2 years ago

4.28.0

2 years ago

4.27.0

2 years ago

4.26.1

2 years ago

4.25.1

2 years ago

4.26.0

2 years ago

4.25.0

2 years ago

4.23.0

2 years ago

4.22.0

2 years ago

4.20.0

2 years ago

4.21.0

2 years ago

4.20.1

2 years ago

4.19.0

2 years ago

4.18.0

2 years ago

4.17.0

2 years ago

4.16.0

2 years ago

4.13.2

2 years ago

4.13.0

2 years ago

4.11.0

2 years ago

4.10.0

2 years ago

4.9.0

2 years ago

4.8.0

2 years ago

4.7.0

2 years ago

4.6.0

2 years ago

4.5.1

2 years ago

4.4.0

2 years ago

4.1.0

3 years ago

3.9.3

3 years ago

3.9.2

3 years ago

4.0.0

3 years ago

3.12.0

3 years ago

3.11.0

3 years ago

3.10.0

3 years ago

3.9.0

3 years ago

3.8.1

3 years ago

3.8.0

3 years ago

3.6.1

3 years ago

3.6.0

3 years ago

3.5.2

3 years ago

3.4.0

3 years ago

3.5.0

3 years ago

3.1.0

3 years ago