import { Nuxt } from '@nuxt/schema';
import { SiteConfigStack, SiteConfigInput, SiteConfigResolved } from 'site-config-stack';
export * from 'site-config-stack';
export { createSitePathResolver, withSiteTrailingSlash, withSiteUrl } from './urls.js';
export { NitroOriginContext, getNitroOrigin, useNitroOrigin } from './util.js';

declare function initSiteConfig(nuxt?: Nuxt | null): Promise<SiteConfigStack | undefined>;
declare function installNuxtSiteConfig(nuxt?: Nuxt | null): Promise<void>;
declare function getSiteConfigStack(nuxt?: Nuxt | null): SiteConfigStack;
declare function updateSiteConfig(input: SiteConfigInput, nuxt?: Nuxt | null): () => void;
declare function useSiteConfig(nuxt?: Nuxt | null): SiteConfigResolved;

type AssertionModes = 'prerender' | 'generate' | 'build';
interface ModuleAssertion {
    context: string;
    requirements: Partial<Record<keyof SiteConfigInput, string>>;
}
declare module '@nuxt/schema' {
    interface Nuxt {
        _siteConfig?: SiteConfigStack;
        _siteConfigAsserts?: Partial<Record<Partial<AssertionModes>, ModuleAssertion[]>>;
    }
}

export { getSiteConfigStack, initSiteConfig, installNuxtSiteConfig, updateSiteConfig, useSiteConfig };
export type { AssertionModes, ModuleAssertion };
