Skip to content
This repository has been archived by the owner on Feb 16, 2024. It is now read-only.

Commit

Permalink
feat: Clear extra files
Browse files Browse the repository at this point in the history
  • Loading branch information
matin-deriv committed Oct 20, 2023
1 parent 1d3ffcc commit fa6622b
Show file tree
Hide file tree
Showing 11 changed files with 3,157 additions and 135 deletions.
3,227 changes: 3,148 additions & 79 deletions package-lock.json

Large diffs are not rendered by default.

29 changes: 7 additions & 22 deletions src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,28 +1,13 @@
import ErrorBoundary from 'Components/common/error-boundary';
import Layout from 'Components/layout';
import AuthProvider from 'Contexts/authProvider';
import { changeLanguage, getInitialLanguage, initializeTranslation } from './translations/i18n';
import { useTranslation } from 'react-i18next';
import { SUPPORTED_LANGUAGES } from 'Constants/translations';

initializeTranslation();

const App = () => {
const { t } = useTranslation();
return (
<AuthProvider>
<ErrorBoundary>
<Layout>{t('Welcome to React')}</Layout>
<select className='select' onChange={e => changeLanguage(e.target.value)} value={getInitialLanguage()}>
{Object.entries(SUPPORTED_LANGUAGES).map(([key, value]) => (
<option key={key} value={key}>
{value}
</option>
))}
</select>
</ErrorBoundary>
</AuthProvider>
);
};
const App = () => (
<AuthProvider>
<ErrorBoundary>
<Layout>App</Layout>
</ErrorBoundary>
</AuthProvider>
);

export default App;
4 changes: 0 additions & 4 deletions src/translations/translation-jsons/de.json

This file was deleted.

4 changes: 2 additions & 2 deletions src/translations/translation-jsons/en.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"Welcome to React": "Welcome to React and react-i18next",
"Click Here": "Click Here"
"Welcome to React": "Welcome to React and react-i18next",
"Click Here": "Click Here"
}
4 changes: 0 additions & 4 deletions src/translations/translation-jsons/es.json

This file was deleted.

4 changes: 0 additions & 4 deletions src/translations/translation-jsons/fr.json

This file was deleted.

4 changes: 0 additions & 4 deletions src/translations/translation-jsons/it.json

This file was deleted.

4 changes: 0 additions & 4 deletions src/translations/translation-jsons/pl.json

This file was deleted.

4 changes: 0 additions & 4 deletions src/translations/translation-jsons/ru.json

This file was deleted.

4 changes: 0 additions & 4 deletions src/translations/translation-jsons/zh_cn.json

This file was deleted.

4 changes: 0 additions & 4 deletions src/translations/translation-jsons/zh_tw.json

This file was deleted.

0 comments on commit fa6622b

Please sign in to comment.