zod-opts
Version:
node.js CLI option parser / validator using Zod
13 lines (12 loc) • 411 B
TypeScript
import { z } from "zod";
import type { Option, PositionalArgument } from "../src/type";
export declare function createOption({ type, alias, description, }: {
type?: z.ZodTypeAny;
alias?: string;
description?: string;
}): Option;
export declare function createPositionalArg({ type, name, description, }: {
type?: z.ZodTypeAny;
name?: string;
description?: string;
}): PositionalArgument;