## API Report File for "@builder.io/qwik-city"

> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).

```ts

import { Component } from '@builder.io/qwik';
import { Cookie } from '@builder.io/qwik-city/middleware/request-handler';
import { CookieOptions } from '@builder.io/qwik-city/middleware/request-handler';
import { CookieValue } from '@builder.io/qwik-city/middleware/request-handler';
import { DeferReturn } from '@builder.io/qwik-city/middleware/request-handler';
import type { EnvGetter } from '@builder.io/qwik-city/middleware/request-handler';
import { JSXNode } from '@builder.io/qwik';
import { JSXOutput } from '@builder.io/qwik';
import { QRL } from '@builder.io/qwik';
import { QRLEventHandlerMulti } from '@builder.io/qwik';
import { QwikIntrinsicElements } from '@builder.io/qwik';
import { QwikJSX } from '@builder.io/qwik';
import type { ReadonlySignal } from '@builder.io/qwik';
import { RequestEvent } from '@builder.io/qwik-city/middleware/request-handler';
import { RequestEventAction } from '@builder.io/qwik-city/middleware/request-handler';
import { RequestEventBase } from '@builder.io/qwik-city/middleware/request-handler';
import { RequestEventCommon } from '@builder.io/qwik-city/middleware/request-handler';
import { RequestEventLoader } from '@builder.io/qwik-city/middleware/request-handler';
import { RequestHandler } from '@builder.io/qwik-city/middleware/request-handler';
import type { ResolveSyncValue } from '@builder.io/qwik-city/middleware/request-handler';
import type * as v from 'valibot';
import type { ValueOrPromise } from '@builder.io/qwik';
import { z } from 'zod';
import type * as z_2 from 'zod';

// @public (undocumented)
export type Action<RETURN, INPUT = Record<string, unknown>, OPTIONAL extends boolean = true> = {
    (): ActionStore<RETURN, INPUT, OPTIONAL>;
};

// @public (undocumented)
export type ActionConstructor = {
    <OBJ extends Record<string, any> | void | null, VALIDATOR extends TypedDataValidator, REST extends [DataValidator, ...DataValidator[]]>(actionQrl: (data: GetValidatorOutputType<VALIDATOR>, event: RequestEventAction) => ValueOrPromise<OBJ>, options: {
        readonly id?: string;
        readonly validation: [VALIDATOR, ...REST];
    }): Action<StrictUnion<OBJ | FailReturn<ValidatorErrorType<GetValidatorInputType<VALIDATOR>>> | FailReturn<FailOfRest<REST>>>, GetValidatorInputType<VALIDATOR>, false>;
    <OBJ extends Record<string, any> | void | null, VALIDATOR extends TypedDataValidator>(actionQrl: (data: GetValidatorOutputType<VALIDATOR>, event: RequestEventAction) => ValueOrPromise<OBJ>, options: {
        readonly id?: string;
        readonly validation: [VALIDATOR];
    }): Action<StrictUnion<OBJ | FailReturn<ValidatorErrorType<GetValidatorInputType<VALIDATOR>>>>, GetValidatorInputType<VALIDATOR>, false>;
    <OBJ extends Record<string, any> | void | null, REST extends [DataValidator, ...DataValidator[]]>(actionQrl: (data: JSONObject, event: RequestEventAction) => ValueOrPromise<OBJ>, options: {
        readonly id?: string;
        readonly validation: REST;
    }): Action<StrictUnion<OBJ | FailReturn<FailOfRest<REST>>>>;
    <OBJ extends Record<string, any> | void | null, VALIDATOR extends TypedDataValidator, REST extends [DataValidator, ...DataValidator[]]>(actionQrl: (data: GetValidatorOutputType<VALIDATOR>, event: RequestEventAction) => ValueOrPromise<OBJ>, options: VALIDATOR, ...rest: REST): Action<StrictUnion<OBJ | FailReturn<ValidatorErrorType<GetValidatorInputType<VALIDATOR>>> | FailReturn<FailOfRest<REST>>>, GetValidatorInputType<VALIDATOR>, false>;
    <OBJ extends Record<string, any> | void | null, VALIDATOR extends TypedDataValidator>(actionQrl: (data: GetValidatorOutputType<VALIDATOR>, event: RequestEventAction) => ValueOrPromise<OBJ>, options: VALIDATOR): Action<StrictUnion<OBJ | FailReturn<ValidatorErrorType<GetValidatorInputType<VALIDATOR>>>>, GetValidatorInputType<VALIDATOR>, false>;
    <OBJ extends Record<string, any> | void | null, REST extends [DataValidator, ...DataValidator[]]>(actionQrl: (form: JSONObject, event: RequestEventAction) => ValueOrPromise<OBJ>, ...rest: REST): Action<StrictUnion<OBJ | FailReturn<FailOfRest<REST>>>>;
    <OBJ>(actionQrl: (form: JSONObject, event: RequestEventAction) => ValueOrPromise<OBJ>, options?: {
        readonly id?: string;
    }): Action<StrictUnion<OBJ>>;
};

// @public (undocumented)
export type ActionReturn<RETURN> = {
    readonly status?: number;
    readonly value: RETURN;
};

// @public (undocumented)
export type ActionStore<RETURN, INPUT, OPTIONAL extends boolean = true> = {
    readonly actionPath: string;
    readonly isRunning: boolean;
    readonly status?: number;
    readonly formData: FormData | undefined;
    readonly value: RETURN | undefined;
    readonly submit: QRL<OPTIONAL extends true ? (form?: INPUT | FormData | SubmitEvent) => Promise<ActionReturn<RETURN>> : (form: INPUT | FormData | SubmitEvent) => Promise<ActionReturn<RETURN>>>;
    readonly submitted: boolean;
};

// @public (undocumented)
export interface ContentHeading {
    // (undocumented)
    readonly id: string;
    // (undocumented)
    readonly level: number;
    // (undocumented)
    readonly text: string;
}

// @public (undocumented)
export interface ContentMenu {
    // (undocumented)
    readonly href?: string;
    // (undocumented)
    readonly items?: ContentMenu[];
    // (undocumented)
    readonly text: string;
}

export { Cookie }

export { CookieOptions }

export { CookieValue }

// @public (undocumented)
export type DataValidator<T extends Record<string, any> = {}> = {
    validate(ev: RequestEvent, data: unknown): Promise<ValidatorReturn<T>>;
};

export { DeferReturn }

// @public (undocumented)
export type DocumentHead = DocumentHeadValue | ((props: DocumentHeadProps) => DocumentHeadValue);

// @public (undocumented)
export interface DocumentHeadProps extends RouteLocation {
    // (undocumented)
    readonly head: ResolvedDocumentHead;
    // (undocumented)
    readonly resolveValue: ResolveSyncValue;
    // (undocumented)
    readonly withLocale: <T>(fn: () => T) => T;
}

// @public (undocumented)
export interface DocumentHeadValue<FrontMatter extends Record<string, any> = Record<string, unknown>> {
    readonly frontmatter?: Readonly<FrontMatter>;
    readonly links?: readonly DocumentLink[];
    readonly meta?: readonly DocumentMeta[];
    // Warning: (ae-incompatible-release-tags) The symbol "scripts" is marked as @public, but its signature references "DocumentScript" which is marked as @alpha
    readonly scripts?: readonly DocumentScript[];
    readonly styles?: readonly DocumentStyle[];
    readonly title?: string;
}

// @public (undocumented)
export interface DocumentLink {
    // (undocumented)
    as?: string;
    // (undocumented)
    crossorigin?: string;
    // (undocumented)
    disabled?: boolean;
    // (undocumented)
    href?: string;
    // (undocumented)
    hreflang?: string;
    // (undocumented)
    id?: string;
    // (undocumented)
    imagesizes?: string;
    // (undocumented)
    imagesrcset?: string;
    // (undocumented)
    integrity?: string;
    // (undocumented)
    key?: string;
    // (undocumented)
    media?: string;
    // (undocumented)
    prefetch?: string;
    // (undocumented)
    referrerpolicy?: string;
    // (undocumented)
    rel?: string;
    // (undocumented)
    sizes?: string;
    // (undocumented)
    title?: string;
    // (undocumented)
    type?: string;
}

// @public (undocumented)
export interface DocumentMeta {
    // (undocumented)
    readonly content?: string;
    // (undocumented)
    readonly httpEquiv?: string;
    // (undocumented)
    readonly itemprop?: string;
    // (undocumented)
    readonly key?: string;
    // (undocumented)
    readonly media?: string;
    // (undocumented)
    readonly name?: string;
    // (undocumented)
    readonly property?: string;
}

// @alpha (undocumented)
export interface DocumentScript {
    // (undocumented)
    readonly key?: string;
    // (undocumented)
    readonly props?: Readonly<QwikIntrinsicElements['script']>;
    // (undocumented)
    readonly script?: string;
}

// @public (undocumented)
export interface DocumentStyle {
    // (undocumented)
    readonly key?: string;
    // (undocumented)
    readonly props?: Readonly<QwikIntrinsicElements['style']>;
    // (undocumented)
    readonly style: string;
}

// @public (undocumented)
export type FailOfRest<REST extends readonly DataValidator[]> = REST extends readonly DataValidator<infer ERROR>[] ? ERROR : never;

// Warning: (ae-forgotten-export) The symbol "Failed" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export type FailReturn<T> = T & Failed;

// @public (undocumented)
export const Form: <O, I>({ action, spaReset, reloadDocument, onSubmit$, ...rest }: FormProps<O, I>, key: string | null) => JSXOutput;

// @public (undocumented)
export interface FormProps<O, I> extends Omit<QwikJSX.IntrinsicElements['form'], 'action' | 'method'> {
    action?: ActionStore<O, I, true | false>;
    // (undocumented)
    key?: string | number | null;
    onSubmit$?: QRLEventHandlerMulti<SubmitEvent, HTMLFormElement> | undefined;
    onSubmitCompleted$?: QRLEventHandlerMulti<CustomEvent<FormSubmitSuccessDetail<O>>, HTMLFormElement> | undefined;
    reloadDocument?: boolean;
    spaReset?: boolean;
}

// @public (undocumented)
export interface FormSubmitSuccessDetail<T> {
    // (undocumented)
    status: number;
    // (undocumented)
    value: T;
}

// Warning: (ae-forgotten-export) The symbol "ValibotDataValidator" needs to be exported by the entry point index.d.ts
// Warning: (ae-forgotten-export) The symbol "ZodDataValidator" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export type GetValidatorInputType<VALIDATOR extends TypedDataValidator> = VALIDATOR extends ValibotDataValidator<infer TYPE> ? v.InferInput<TYPE> : VALIDATOR extends ZodDataValidator<infer TYPE> ? z_2.input<TYPE> : never;

// @public (undocumented)
export type GetValidatorOutputType<VALIDATOR extends TypedDataValidator> = VALIDATOR extends ValibotDataValidator<infer TYPE> ? v.InferOutput<TYPE> : VALIDATOR extends ZodDataValidator<infer TYPE> ? z_2.output<TYPE> : never;

// @public (undocumented)
export type GetValidatorType<VALIDATOR extends TypedDataValidator> = GetValidatorOutputType<VALIDATOR>;

// @public (undocumented)
export const globalAction$: ActionConstructor;

// Warning: (ae-forgotten-export) The symbol "ActionConstructorQRL" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const globalActionQrl: ActionConstructorQRL;

// @public (undocumented)
export type JSONObject = {
    [x: string]: JSONValue;
};

// @public (undocumented)
export type JSONValue = string | number | boolean | {
    [x: string]: JSONValue;
} | Array<JSONValue>;

// @public (undocumented)
export const Link: Component<LinkProps>;

// Warning: (ae-forgotten-export) The symbol "AnchorAttributes" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export interface LinkProps extends AnchorAttributes {
    prefetch?: boolean | 'js';
    // (undocumented)
    reload?: boolean;
    // (undocumented)
    replaceState?: boolean;
    // (undocumented)
    scroll?: boolean;
}

// @public (undocumented)
type Loader_2<RETURN> = {
    (): LoaderSignal<RETURN>;
};
export { Loader_2 as Loader }

// @public (undocumented)
export type LoaderSignal<TYPE> = TYPE extends () => ValueOrPromise<infer VALIDATOR> ? ReadonlySignal<ValueOrPromise<VALIDATOR>> : ReadonlySignal<TYPE>;

// Warning: (ae-forgotten-export) The symbol "MenuModuleLoader" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export type MenuData = [pathname: string, menuLoader: MenuModuleLoader];

// @public (undocumented)
export type NavigationType = 'initial' | 'form' | 'link' | 'popstate';

// Warning: (ae-forgotten-export) The symbol "RouteModule" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export interface PageModule extends RouteModule {
    // (undocumented)
    readonly default: unknown;
    // Warning: (ae-forgotten-export) The symbol "ContentModuleHead" needs to be exported by the entry point index.d.ts
    //
    // (undocumented)
    readonly head?: ContentModuleHead;
    // (undocumented)
    readonly headings?: ContentHeading[];
    // (undocumented)
    readonly onStaticGenerate?: StaticGenerateHandler;
}

// @public (undocumented)
export type PathParams = Record<string, string>;

// @public (undocumented)
export type PreventNavigateCallback = (url?: number | URL) => ValueOrPromise<boolean>;

// @public (undocumented)
export const QWIK_CITY_SCROLLER = "_qCityScroller";

// @public (undocumented)
export interface QwikCityMockProps {
    // (undocumented)
    goto?: RouteNavigate;
    // (undocumented)
    params?: Record<string, string>;
    // (undocumented)
    url?: string;
}

// @public (undocumented)
export const QwikCityMockProvider: Component<QwikCityMockProps>;

// @public (undocumented)
export interface QwikCityPlan {
    // (undocumented)
    readonly basePathname?: string;
    // (undocumented)
    readonly cacheModules?: boolean;
    // (undocumented)
    readonly menus?: MenuData[];
    // (undocumented)
    readonly routes: RouteData[];
    // (undocumented)
    readonly serverPlugins?: RouteModule[];
    // (undocumented)
    readonly trailingSlash?: boolean;
}

// @public (undocumented)
export interface QwikCityProps {
    viewTransition?: boolean;
}

// @public (undocumented)
export const QwikCityProvider: Component<QwikCityProps>;

export { RequestEvent }

export { RequestEventAction }

export { RequestEventBase }

export { RequestEventCommon }

export { RequestEventLoader }

export { RequestHandler }

// @public (undocumented)
export type ResolvedDocumentHead<FrontMatter extends Record<string, any> = Record<string, unknown>> = Required<DocumentHeadValue<FrontMatter>>;

// @public (undocumented)
export const routeAction$: ActionConstructor;

// @public (undocumented)
export const routeActionQrl: ActionConstructorQRL;

// Warning: (ae-forgotten-export) The symbol "ModuleLoader" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export type RouteData = [routeName: string, loaders: ModuleLoader[]] | [
routeName: string,
loaders: ModuleLoader[],
originalPathname: string,
routeBundleNames: string[]
];

// Warning: (ae-forgotten-export) The symbol "LoaderConstructor" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const routeLoader$: LoaderConstructor;

// Warning: (ae-forgotten-export) The symbol "LoaderConstructorQRL" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const routeLoaderQrl: LoaderConstructorQRL;

// @public (undocumented)
export interface RouteLocation {
    // (undocumented)
    readonly isNavigating: boolean;
    // (undocumented)
    readonly params: Readonly<Record<string, string>>;
    // (undocumented)
    readonly prevUrl: URL | undefined;
    // (undocumented)
    readonly url: URL;
}

// @public (undocumented)
export type RouteNavigate = QRL<(path?: string | number | URL, options?: {
    type?: Exclude<NavigationType, 'initial'>;
    forceReload?: boolean;
    replaceState?: boolean;
    scroll?: boolean;
} | boolean) => Promise<void>>;

// @public (undocumented)
export const RouterOutlet: Component<unknown>;

// Warning: (ae-forgotten-export) The symbol "ServerConfig" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const server$: <T extends ServerFunction>(qrl: T, options?: ServerConfig | undefined) => ServerQRL<T>;

// @public (undocumented)
export type ServerFunction = {
    (this: RequestEventBase, ...args: any[]): any;
    options?: ServerConfig;
};

// @public
export type ServerQRL<T extends ServerFunction> = QRL<((abort: AbortSignal, ...args: Parameters<T>) => ReturnType<T>) | ((...args: Parameters<T>) => ReturnType<T>)>;

// @public (undocumented)
export const serverQrl: <T extends ServerFunction>(qrl: QRL<T>, options?: ServerConfig) => ServerQRL<T>;

// @public (undocumented)
export const ServiceWorkerRegister: (props: {
    nonce?: string;
}) => JSXNode<"script">;

// @public (undocumented)
export interface StaticGenerate {
    // (undocumented)
    params?: PathParams[];
}

// @public (undocumented)
export type StaticGenerateHandler = ({ env, }: {
    env: EnvGetter;
}) => Promise<StaticGenerate> | StaticGenerate;

// Warning: (ae-forgotten-export) The symbol "Prettify" needs to be exported by the entry point index.d.ts
// Warning: (ae-forgotten-export) The symbol "StrictUnionHelper" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export type StrictUnion<T> = Prettify<StrictUnionHelper<T, T>>;

// @public (undocumented)
export type TypedDataValidator = ValibotDataValidator | ZodDataValidator;

// Warning: (ae-forgotten-export) The symbol "ContentState" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const useContent: () => ContentState;

// @public
export const useDocumentHead: <FrontMatter extends Record<string, unknown> = Record<string, any>>() => Required<ResolvedDocumentHead<FrontMatter>>;

// @public (undocumented)
export const useLocation: () => RouteLocation;

// @public (undocumented)
export const useNavigate: () => RouteNavigate;

// @public
export const usePreventNavigate$: (qrl: PreventNavigateCallback) => void;

// Warning: (ae-internal-missing-underscore) The name "usePreventNavigateQrl" should be prefixed with an underscore because the declaration is marked as @internal
//
// @internal
export const usePreventNavigateQrl: (fn: QRL<PreventNavigateCallback>) => void;

// Warning: (ae-forgotten-export) The symbol "ValibotConstructor" needs to be exported by the entry point index.d.ts
//
// @alpha (undocumented)
export const valibot$: ValibotConstructor;

// Warning: (ae-forgotten-export) The symbol "ValibotConstructorQRL" needs to be exported by the entry point index.d.ts
//
// @alpha (undocumented)
export const valibotQrl: ValibotConstructorQRL;

// Warning: (ae-forgotten-export) The symbol "ValidatorConstructor" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const validator$: ValidatorConstructor;

// Warning: (ae-forgotten-export) The symbol "IsAny" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export type ValidatorErrorKeyDotNotation<T, Prefix extends string = ''> = IsAny<T> extends true ? never : T extends object ? {
    [K in keyof T & string]: IsAny<T[K]> extends true ? never : T[K] extends (infer U)[] ? IsAny<U> extends true ? never : U extends object ? `${Prefix}${K}[]` | ValidatorErrorKeyDotNotation<U, `${Prefix}${K}[].`> : `${Prefix}${K}[]` : T[K] extends object ? ValidatorErrorKeyDotNotation<T[K], `${Prefix}${K}.`> : `${Prefix}${K}`;
}[keyof T & string] : never;

// @public (undocumented)
export type ValidatorErrorType<T, U = string> = {
    formErrors: U[];
    fieldErrors: Partial<{
        [K in ValidatorErrorKeyDotNotation<T>]: K extends `${infer _Prefix}[]${infer _Suffix}` ? U[] : U;
    }>;
};

// Warning: (ae-forgotten-export) The symbol "ValidatorConstructorQRL" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const validatorQrl: ValidatorConstructorQRL;

// Warning: (ae-forgotten-export) The symbol "ValidatorReturnSuccess" needs to be exported by the entry point index.d.ts
// Warning: (ae-forgotten-export) The symbol "ValidatorReturnFail" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export type ValidatorReturn<T extends Record<string, any> = {}> = ValidatorReturnSuccess | ValidatorReturnFail<T>;

export { z }

// @public (undocumented)
export const zod$: ZodConstructor;

// @public (undocumented)
export type ZodConstructor = {
    <T extends z_2.ZodRawShape>(schema: T): ZodDataValidator<z_2.ZodObject<T>>;
    <T extends z_2.ZodRawShape>(schema: (zod: typeof z_2.z, ev: RequestEvent) => T): ZodDataValidator<z_2.ZodObject<T>>;
    <T extends z_2.Schema>(schema: T): ZodDataValidator<T>;
    <T extends z_2.Schema>(schema: (zod: typeof z_2.z, ev: RequestEvent) => T): ZodDataValidator<T>;
};

// Warning: (ae-forgotten-export) The symbol "ZodConstructorQRL" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const zodQrl: ZodConstructorQRL;

// (No @packageDocumentation comment for this package)

```
