edgespec
Version:
Write Winter-CG compatible routes with filesystem routing and tons of features
39 lines (36 loc) • 1.45 kB
TypeScript
import { z } from 'zod';
declare const edgeSpecConfigSchema: z.ZodObject<{
/**
* Defaults to the current working directory.
*/
rootDirectory: z.ZodOptional<z.ZodString>;
/**
* If this path is relative, it's resolved relative to the `rootDirectory` option.
*/
tsconfigPath: z.ZodOptional<z.ZodString>;
/**
* If this path is relative, it's resolved relative to the `rootDirectory` option.
*/
routesDirectory: z.ZodOptional<z.ZodString>;
/**
* The platform you're targeting.
*
* Defaults to `wintercg-minimal`, and you should use this whenever possible for maximal compatibility.
*
* Check [the docs](https://github.com/seamapi/edgespec/blob/main/docs/edgespec-config.md) for more information.
*/
platform: z.ZodOptional<z.ZodDefault<z.ZodEnum<["node", "wintercg-minimal"]>>>;
}, "strict", z.ZodTypeAny, {
rootDirectory?: string | undefined;
tsconfigPath?: string | undefined;
routesDirectory?: string | undefined;
platform?: "node" | "wintercg-minimal" | undefined;
}, {
rootDirectory?: string | undefined;
tsconfigPath?: string | undefined;
routesDirectory?: string | undefined;
platform?: "node" | "wintercg-minimal" | undefined;
}>;
type EdgeSpecConfig = z.infer<typeof edgeSpecConfigSchema>;
declare const defineConfig: (config: EdgeSpecConfig) => EdgeSpecConfig;
export { type EdgeSpecConfig as E, defineConfig as d };