revite/src/context/Locale.tsx

11 lines
295 B
TypeScript
Raw Normal View History

2021-06-18 10:18:10 -04:00
import { IntlProvider } from "preact-i18n";
import definition from "../../external/lang/en.json";
interface Props {
2021-06-18 10:57:08 -04:00
children: JSX.Element | JSX.Element[];
2021-06-18 10:18:10 -04:00
}
export default function Locale({ children }: Props) {
2021-06-18 10:57:08 -04:00
return <IntlProvider definition={definition}>{children}</IntlProvider>;
2021-06-18 10:18:10 -04:00
}