next-intlayer
Version:
Simplify internationalization i18n in Next.js with context providers, hooks, locale detection, and multilingual content integration.
19 lines (18 loc) • 602 B
TypeScript
import * as _intlayer_types0 from "@intlayer/types";
import { LocalesValues } from "@intlayer/types";
//#region src/client/useLocale.d.ts
type UseLocaleProps = {
onChange?: 'replace' | 'push' | ((locale: LocalesValues) => void);
};
declare const useLocale: ({
onChange
}?: UseLocaleProps) => {
pathWithoutLocale: string;
locale: _intlayer_types0.DeclaredLocales;
defaultLocale: _intlayer_types0.DeclaredLocales;
availableLocales: _intlayer_types0.DeclaredLocales[];
setLocale: (locale: LocalesValues) => void;
};
//#endregion
export { useLocale };
//# sourceMappingURL=useLocale.d.ts.map