import { NestedMessages } from "./index.js";
//#region src/loader.d.ts
declare class BundleLoadError extends Error {
  readonly locale: string;
  readonly namespace?: string | undefined;
  constructor(locale: string, namespace?: string | undefined);
}
type BundleLoaderFn<L extends string> = (locale: L, namespace?: string) => Promise<NestedMessages | null | undefined>;
interface BundleLoader<L extends string = string> {
  load(locale: L, namespace?: string): Promise<NestedMessages>;
  peek(locale: L, namespace?: string): NestedMessages | undefined;
  clear(): void;
}
declare function createBundleLoader<L extends string>(loadFn: BundleLoaderFn<L>): BundleLoader<L>;
//#endregion
export { BundleLoadError, BundleLoader, BundleLoaderFn, createBundleLoader };