Skip to content

Interface: ParserOptions<T>

Defined in: packages/parser/src/types.ts:73

Configuration options for the parser.

Type Parameters

T

T extends FlagsDefinition = { }

Properties

delimiters?

ts
optional delimiters: string[];

Defined in: packages/parser/src/types.ts:86

Delimiters to split flag names and values.

Default

ts
["=", ":"];

flags?

ts
optional flags: T;

Defined in: packages/parser/src/types.ts:79

Detailed configuration for flags. Supports the full object syntax or a type constructor as a shorthand. The key is the flag name (e.g., "file" for "--file").


ignore?

ts
optional ignore: IgnoreFunction;

Defined in: packages/parser/src/types.ts:92

A callback function to conditionally stop parsing. When it returns true, parsing stops and remaining arguments are preserved in ignored.

Released under the MIT license