Class ZodFunction<Args, Returns>

Type Parameters

Hierarchy (View Summary)

Constructors

Properties

spa: (
    data: unknown,
    params?: Partial<Zod.z.ParseParams>,
) => Promise<
    Zod.z.SafeParseReturnType<
        Zod.z.InnerTypeOfFunction<Args, Returns>,
        Zod.z.OuterTypeOfFunction<Args, Returns>,
    >,
>

Alias of safeParseAsync

validate: <F extends (...args: any[any]) => Returns["_input"]>(
    func: F,
) => ReturnType<F> extends Returns["_output"]
    ? (...args: Args["_input"]) => ReturnType<ReturnType<F>>
    : Zod.z.OuterTypeOfFunction<Args, Returns>

Accessors

  • get description(): undefined | string
  • Returns undefined | string

Methods

  • Parameters

    • description: string

    Returns this

  • Returns boolean

  • Returns boolean

  • Returns Args

  • Returns Returns