The essential building blocks for creating CLIs with bargs.
Start here: bargs() creates a CLI, opt defines options, pos defines positionals.
Functions for composing and transforming parsers.
Use map() to transform results, merge() to combine parsers, and handle() to attach handlers.
Help text generation for CLI applications. Customize help output with themes and formatting options.
Styling and color customization for help output. Includes ANSI codes, built-in themes, and custom theme support.
Terminal feature detection and utilities. Includes hyperlink support detection and URL linkification.
Type definitions for CLI option configurations.
Type definitions for positional argument configurations.
Core parser and result types for the combinator pipeline.
Advanced TypeScript utilities for type inference and transformation.
Main entry point for the bargs CLI argument parser.
Provides a combinator-style API for building type-safe CLIs.
Example