Skip to main content
Module

x/args/index.ts>valueErrors.InvalidChoice

Extensible CLI arguments parser for Deno with intelligent TypeScript inference
Latest
class valueErrors.InvalidChoice
extends ValueError
import { valueErrors } from "https://deno.land/x/args@2.1.1/index.ts";
const { InvalidChoice } = valueErrors;

ValueError class for when raw input not matching any expected choice

Constructors

new
InvalidChoice(raw: string, choices: readonly ValidChoice[])

Type Parameters

ValidChoice extends string | number

Union type of valid choices