mirror of
https://github.com/R0m1k3/Priceflow.git
synced 2026-10-21 06:08:12 +02:00
fix: Rename use-auth.js to use-auth.jsx for JSX support
This commit is contained in:
2875 files changed
+459559
-2
No files matched your search
+19
@@ -0,0 +1,19 @@
|
||||
import { createElement, useMemo } from 'react';
|
||||
import { I18nContext } from './context.js';
|
||||
|
||||
export function I18nextProvider({ i18n, defaultNS, children }) {
|
||||
const value = useMemo(
|
||||
() => ({
|
||||
i18n,
|
||||
defaultNS,
|
||||
}),
|
||||
[i18n, defaultNS],
|
||||
);
|
||||
return createElement(
|
||||
I18nContext.Provider,
|
||||
{
|
||||
value,
|
||||
},
|
||||
children,
|
||||
);
|
||||
}
|
||||
Reference in new issue
Block a user