Skip to main content
Module

x/args/value-errors.ts>InvalidChoice

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

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