Add i18n, use default imports for UI.

This commit is contained in:
Paul
2021-06-18 15:18:10 +01:00
parent 9ac2316ed0
commit 58821476e6
17 changed files with 90 additions and 54 deletions

14
src/context/Locale.tsx Normal file
View File

@@ -0,0 +1,14 @@
import { IntlProvider } from "preact-i18n";
import definition from "../../external/lang/en.json";
interface Props {
children: JSX.Element | JSX.Element[]
}
export default function Locale({ children }: Props) {
return (
<IntlProvider definition={definition}>
{ children }
</IntlProvider>
)
}