Issue with Localization Conflict in Web3Auth

Please provide the following details too when asking for help in this category:
I am encountering an issue where Web3Auth and my project, both using the same i18n localization framework, are conflicting with each other. This conflict results in unexpected behavior when translations are loaded.

  • SDK Version: @web3auth/modal: 7.0.2
  • Platform: ReactJS
  • Browser Console Screenshots: N/A

Please provide the Web3Auth initialization and login code snippet below:
My project’s localization setup is described in the code snippet below:
./localization.index.ts:

import i18n from 'i18next';
import { initReactI18next } from 'react-i18next';
import en from './en';

export const resources = { en } as const;
export const defaultNS = 'common';

i18n.use(initReactI18next).init({
  resources,
  lng: 'en',
  fallbackLng: 'en',
  interpolation: {
    escapeValue: false,
  },
  defaultNS,
});

./localization.en.ts:

export default {
  common: {
    // Localization keys and strings
  },
};

./src/index.tsx:

import 'localization';

const root = ReactDOM.createRoot(
  document.getElementById('root') as HTMLElement,
);
root.render(
  <React.StrictMode>
      <App />
  </React.StrictMode>
);

1 Like

@olya1churyk Welcome Aboard!

Your issue is under review and we will get back with further updates.

1 Like

Hi @olya1churyk, try updating to v7.0.4 and check if this is resolved for you.

3 Likes

Hi @maharshi
New version does work as expected, thank you very much for your support) :unicorn: :unicorn: :unicorn:

3 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.