import type { ActionFunction, LoaderFunction } from "../router/utils";
import type { ClientActionFunction, ClientLoaderFunction, LinksFunction, MetaFunction } from "../dom/ssr/routeModules";
export interface RouteModules<RouteModule> {
    [routeId: string]: RouteModule | undefined;
}
export type HeadersArgs = {
    loaderHeaders: Headers;
    parentHeaders: Headers;
    actionHeaders: Headers;
    errorHeaders: Headers | undefined;
};
/**
 * A function that returns HTTP headers to be used for a route. These headers
 * will be merged with (and take precedence over) headers from parent routes.
 */
export interface HeadersFunction {
    (args: HeadersArgs): Headers | HeadersInit;
}
/**
 * An arbitrary object that is associated with a route.
 */
export type RouteHandle = unknown;
export interface EntryRouteModule {
    clientAction?: ClientActionFunction;
    clientLoader?: ClientLoaderFunction;
    ErrorBoundary?: any;
    HydrateFallback?: any;
    Layout?: any;
    default: any;
    handle?: RouteHandle;
    links?: LinksFunction;
    meta?: MetaFunction;
}
export interface ServerRouteModule extends EntryRouteModule {
    action?: ActionFunction;
    headers?: HeadersFunction | {
        [name: string]: string;
    };
    loader?: LoaderFunction;
}
