Skip to content
Snippets Groups Projects
Select Git revision
  • 726376dbb3e660586094fa3e3dfa08f808689cc0
  • master default protected
2 results

cycle3

Blame
  • i18n.js 467 B
    import i18n from 'i18next';
    import { reactI18nextModule } from 'react-i18next';
    import de from '../locales/de/translation.json';
    import en from '../locales/en/translation.json';
    
    
    // Load translations for each language
    const resources = {
      de,
      en,
    };
    
    i18n
      .use(reactI18nextModule)
      .init({
        resources,
        lng: 'en',
        fallbackLng: 'en',
    
        interpolation: {
          escapeValue: false, // react is already safe from xss
        },
      });
    
    export default i18n;