Skip to main content
Module

x/args/flag-types.ts>Partial

Extensible CLI arguments parser for Deno with intelligent TypeScript inference
Latest
variable Partial
import { Partial } from "https://deno.land/x/args@2.1.1/flag-types.ts";

Turn an option partial:

  • If the option does not have a value, return default value
  • If the option has a value, return that value

type

<Name extends string, Value, Default>(
x: FlagType<Name, Value>,
def: Default,
descDef?: string,
) => FlagType<Name, Value | Default>