0.1.3 • Published 11 months ago
@puzzlet/locales v0.1.3
To start using it do the following
- Create i18n file e.g i18nInit
- Initialize i18n by using the exported method init
- Add translation files as param
- import the created file (i18Init) to entry point of you app.
Note: Make sure you use "use client" at the top of file in your next app.
Exmaple
"use client"; import { init } from "@puzzlet/locales"; import translationEn from "./langs/en.json";
init({ translations: { en: translationEn } });