UNPKG

@vyxos/astro-i18next

Version:

I18next integration for Astro with dynamic namespace loading.

25 lines (22 loc) 789 B
export { I as IntegrationOptions } from './types-BHBGla7c.cjs'; /** * TanStack Router integration utilities for namespace loading */ /** * Helper function to load namespaces for a route in TanStack Router beforeLoad * Usage in your route config: * * beforeLoad: async () => { * await loadNamespacesForRoute(['common', 'auth', 'dashboard']); * } */ declare function loadNamespacesForRoute(namespaces: string[]): Promise<void>; /** * React hook for loading namespaces in components (optional usage) */ declare function useLoadNamespaces(namespaces: string[]): Promise<void>; /** * Preload namespaces without waiting (fire-and-forget) */ declare function preloadNamespaces(namespaces: string[]): void; export { loadNamespacesForRoute, preloadNamespaces, useLoadNamespaces };