Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/quavedev/react-i18n

React i18n components
https://github.com/quavedev/react-i18n

Last synced: about 2 months ago
JSON representation

React i18n components

Awesome Lists containing this project

README

        

# React i18n components

## Usage

### Adding npm dependency in your project

```shell
npm i @quave/react-i18n
```

```javascript
import { ENGLISH, PORTUGUESE, LanguageChange, useTranslate, Store } from '@quave/react-i18n';

export const TERMS = {
pageTitle: {
[ENGLISH]: 'English page title',
[PORTUGUESE]: 'Título da página em português',
},
};

const LanguageTest = () => {
const { i18n } = useTranslate();
return

{i18n('pageTitle')}
;
};

export const App = () => (




);
```