Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: isolate i18next instance #14

Merged
merged 2 commits into from
Oct 13, 2022
Merged

fix: isolate i18next instance #14

merged 2 commits into from
Oct 13, 2022

Conversation

StanleyDing
Copy link
Contributor

What this commit solves

If the project using this widget is also using i18next (like us), current code will initialize user's i18next twice. This PR creates a new instance that is provided through react provider, so it won't have side-effect on user's i18next instance.

Things to improve in the future

Let users pass their own i18next instance or an option to overwrite current translation files.

@chybisov
Copy link
Member

chybisov commented Oct 12, 2022

@StanleyDing hi, thank you for this PR. Yes, this makes total sense. I'll make some tests, and we can merge it 🙂 Translation configuration is planned and certainly will be available soon.

@chybisov chybisov merged commit e2ff741 into lifinance:main Oct 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants