Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/args/index.ts>flags.BinaryFlag

Extensible CLI arguments parser for Deno with intelligent TypeScript inference
Latest
variable flags.BinaryFlag
import { flags } from "https://deno.land/x/args@2.1.1/index.ts";
const { BinaryFlag } = flags;

Declare a binary flag:

  • value is true if the flag is found in argument list once or multiple times
  • value is false if the flag isn't found in argument list

type

<Name extends string>(name: Name, descriptor?: FlagDescriptor) => FlagType<Name, boolean>