Module

x/zod/index.ts>z.util.arrayToEnum

TypeScript-first schema validation with static type inference
Extremely Popular
Go to Latest
variable z.util.arrayToEnum
import { z } from "https://dotland.deno.dev/x/zod@v3.22.1/index.ts";
const { arrayToEnum } = z.util;

type

<T extends string, U extends [T, ...T[]]>(items: U) => [k in U[number]]: k