# Stricli > Build complex CLIs with type safety and no dependencies ## Stricli - [Features](/stricli/docs/category/features.md) - [Getting Started](/stricli/docs/category/getting-started.md): Everything about what Stricli is and where it fits in the larger ecosystem. - [Argument Parsing](/stricli/docs/features/argument-parsing.md): Extending from our core principle of When Parsing, Form Follows Function, Stricli infers the shape of parameter definitions from the TypeScript types used in the implementation. This is achieved with some advanced conditional types that map the types of the parameters to the types of the parser specifications. - [Named Flags](/stricli/docs/features/argument-parsing/flags.md): Flags are named, non-positional arguments that are passed to a command. They can be passed in any order, and depending on the type and configuration can be repeated or excluded. - [Positional Arguments](/stricli/docs/features/argument-parsing/positional.md): All non-flag arguments passed to the CLI are considered in order, parsed, and then passed to the rest arguments of the command. While flags can be parsed or additionally support a variety of built-in types, all positional arguments must be parsed from strings with a provided parser. These support any strings, but by default any inputs starting with - or -- will be interpreted as flags instead. To escape this behavior, consider using the argument escape sequence. - [Command Routing](/stricli/docs/features/command-routing.md): Applications are the top-level object that encapsulate all of the logic for a given CLI application. They can be built with a single command as the root or a route map of nested subcommands. - [Commands](/stricli/docs/features/command-routing/commands.md): Commands are the true building blocks of any CLI application. In order to create a new command, call the buildCommand function with the entire specification for that command's parameters and documentation. The argument object for the builder accepts the following properties. - [Route Maps](/stricli/docs/features/command-routing/route-maps.md): For CLI applications with more than one command, route maps are the way to organize and nest these commands so that they are accessible to users. In order to create a new route map, call the buildRouteMap function with a mapping of route names to targets. The argument object for the builder accepts the following properties. - [Configuration](/stricli/docs/features/configuration.md): The Stricli framework was designed to give applications the maximum amount of flexibility within the predefined constraints. When building an application, you can specify additional configurations to control the application behavior in different ways. - [Integrations](/stricli/docs/features/integrations.md): Integrations are a way to provide additional functionality to a Stricli application without requiring the application to implement that functionality itself. - [Help Text](/stricli/docs/features/integrations/help-text.md): The help integration provides the built-in --help (and --helpAll) flags for Stricli applications. It accepts the additional flag properties for an integration, but also has additional properties to control the formatting of the help text. The formatting object is a subset of the now-deprecated documentation configuration object, and is used to control the formatting of the help text. - [Version Information](/stricli/docs/features/integrations/version-information.md): One common requirement of CLI applications is to display their own current version. The version integration provides a built-in --version flag for Stricli applications, and registers a hook to provide a warning. It accepts the additional flag properties for an integration, but also has additional properties to control how the version information is displayed. The info object in the options is a copy of the now-deprecated versionInfo configuration object. - [Isolated Context](/stricli/docs/features/isolated-context.md): For the core functionality of parsing input and writing to the terminal, command line applications require few external dependencies. They need to be able to write to stdout for console output and stderr for errors. For Stricli, these requirements are encapsulated in the CommandContext type. - [Out of Scope](/stricli/docs/features/out-of-scope.md): Stricli has a lot of features (see Features) but it was not designed to solve every problem. It was deliberately created to have a limited feature set and then excel at those. The following features were all determined to be out-of-scope and are better solved manually or with an existing library. - [Shell Autocomplete](/stricli/docs/features/shell-autocomplete.md): Stricli has first class support for tab auto completion in shells. - [Alternatives Considered](/stricli/docs/getting-started/alternatives.md): Given the large number of libraries and frameworks in the JavaScript ecosystem already, it makes sense to justify why those were deemed insufficient or otherwise a poor fit especially when floating the notion of creating yet another library. The reasoning provided here is non-exhaustive and only serves as a summary of why it was not chosen. - [Frequently Asked Questions](/stricli/docs/getting-started/faq.md): Why is it called "stricli"? - [Overview](/stricli/docs/getting-started/overview.md): Stricli is a zero-dependency framework for building complex, highly-featured CLIs in TypeScript. - [Guiding Principles](/stricli/docs/getting-started/principles.md): Much of this work was inspired by and built upon the incredible Command Line Interface Guidelines. They are a set of open-source rules and recommendations for developing command line interfaces. This framework adheres to these guidelines, but it does not implement all of them. Some features were considered out-of-scope for this framework, and are already solved by existing packages in the ecosystem. - [Quick Start](/stricli/docs/quick-start.md): This quick start guide will get you started with a new, empty Stricli application and show you how to modify it to suit your needs. - [Testing](/stricli/docs/testing.md): Stricli commands are designed to run with a provided context, which makes it easier to write isolated tests. Most commands can be tested in one of two ways, depending on construction: - [Packages](/stricli/packages.md): - @stricli/core - [@stricli/auto-complete](/stricli/packages/auto-complete.md): Common utilities for enhancing Stricli applications with autocomplete - [Function: buildInstallCommand()](/stricli/packages/auto-complete/functions/buildInstallCommand.md): buildInstallCommand\(targetCommand, commands): Command\ - [Function: buildUninstallCommand()](/stricli/packages/auto-complete/functions/buildUninstallCommand.md): buildUninstallCommand\(targetCommand, shells): Command\ - [@stricli/auto-complete](/stricli/packages/auto-complete/globals.md): Interfaces - [Interface: StricliAutoCompleteContext](/stricli/packages/auto-complete/interfaces/StricliAutoCompleteContext.md): Extends - [@stricli/core](/stricli/packages/core.md): Build complex CLIs with type safety and no dependencies - [Class: AliasNotFoundError](/stricli/packages/core/classes/AliasNotFoundError.md): Thrown when input suggests an alias, but no alias with that letter was found. - [Class: ArgumentParseError](/stricli/packages/core/classes/ArgumentParseError.md): Thrown when underlying parameter parser throws an exception parsing some input. - [Class: abstract ArgumentScannerError](/stricli/packages/core/classes/ArgumentScannerError.md): Abstract class that all internal argument scanner errors extend from. - [Class: EnumValidationError](/stricli/packages/core/classes/EnumValidationError.md): Thrown when input fails to match the given values for an enum flag. - [Class: FlagNotFoundError](/stricli/packages/core/classes/FlagNotFoundError.md): Thrown when input suggests an flag, but no flag with that name was found. - [Class: InvalidNegatedFlagSyntaxError](/stricli/packages/core/classes/InvalidNegatedFlagSyntaxError.md): Thrown when a value is provided for a negated flag. - [Class: UnexpectedFlagError](/stricli/packages/core/classes/UnexpectedFlagError.md): Thrown when single-valued flag encounters more than one value. - [Class: UnexpectedPositionalError](/stricli/packages/core/classes/UnexpectedPositionalError.md): Thrown when too many positional arguments were encountered. - [Class: UnsatisfiedFlagError](/stricli/packages/core/classes/UnsatisfiedFlagError.md): Thrown when flag was expecting input that was not provided. - [Class: UnsatisfiedPositionalError](/stricli/packages/core/classes/UnsatisfiedPositionalError.md): Thrown when positional parameter was expecting input that was not provided. - [Function: booleanParser()](/stricli/packages/core/functions/booleanParser.md): booleanParser(input): boolean - [Function: buildApplication()](/stricli/packages/core/functions/buildApplication.md): buildApplication(root, config, integrations) - [Function: buildChoiceParser()](/stricli/packages/core/functions/buildChoiceParser.md): buildChoiceParser\(choices): InputParser\ - [Function: buildCommand()](/stricli/packages/core/functions/buildCommand.md): buildCommand\(builderArgs): Command\ - [Function: buildRouteMap()](/stricli/packages/core/functions/buildRouteMap.md): buildRouteMap\(namedParameters): RouteMap\ - [Function: formatMessageForArgumentScannerError()](/stricli/packages/core/functions/formatMessageForArgumentScannerError.md): formatMessageForArgumentScannerError(error, formatter): string - [Function: generateHelpTextForAllCommands()](/stricli/packages/core/functions/generateHelpTextForAllCommands.md): generateHelpTextForAllCommands(namedParameters, locale?): readonly DocumentedCommand[] - [Function: help()](/stricli/packages/core/functions/help.md): help\(namedParameters): StricliIntegration\ - [Function: looseBooleanParser()](/stricli/packages/core/functions/looseBooleanParser.md): looseBooleanParser(input): boolean - [Function: numberParser()](/stricli/packages/core/functions/numberParser.md): numberParser(input): number - [Function: proposeCompletions()](/stricli/packages/core/functions/proposeCompletions.md): proposeCompletions\(namedParameters, rawInputs, context): Promise\ - [Function: run()](/stricli/packages/core/functions/run.md): run\(app, inputs, context): Promise\ - [Function: version()](/stricli/packages/core/functions/version.md): version\(namedParameters): StricliIntegration\ - [@stricli/core](/stricli/packages/core/globals.md): Classes - [Interface: Application](/stricli/packages/core/interfaces/Application.md): Interface for top-level command line application. - [Interface: ApplicationConfiguration](/stricli/packages/core/interfaces/ApplicationConfiguration.md): Configuration for controlling the runtime behavior of the application. - [Interface: ApplicationContext](/stricli/packages/core/interfaces/ApplicationContext.md): Top-level context that provides necessary process information to Stricli internals. - [Interface: ApplicationErrorFormatting](/stricli/packages/core/interfaces/ApplicationErrorFormatting.md): Methods to customize the formatting of stderr messages handled by application execution. - [Interface: ApplicationText](/stricli/packages/core/interfaces/ApplicationText.md): The full set of static text and text-returning callbacks that are necessary for Stricli to write the necessary output. - [Interface: Command](/stricli/packages/core/interfaces/Command.md): Parsed and validated command instance. - [Interface: CommandContext](/stricli/packages/core/interfaces/CommandContext.md): Command-level context that provides necessary process information and is available to all command runs. - [Interface: CommandInfo](/stricli/packages/core/interfaces/CommandInfo.md): Contextual information about the current command. - [Interface: CommandModule](/stricli/packages/core/interfaces/CommandModule.md): A command module exposes the target function as the default export. - [Interface: CompletionConfiguration](/stricli/packages/core/interfaces/CompletionConfiguration.md): Configuration for controlling the behavior of completion proposals. - [Interface: DocumentationBriefs](/stricli/packages/core/interfaces/DocumentationBriefs.md): Short documentation brief strings used to build help text. - [Interface: DocumentationConfiguration](/stricli/packages/core/interfaces/DocumentationConfiguration.md): Configuration for controlling the content of the printed documentation. - [Interface: DocumentationHeaders](/stricli/packages/core/interfaces/DocumentationHeaders.md): Section header strings used to build help text. - [Interface: DocumentationKeywords](/stricli/packages/core/interfaces/DocumentationKeywords.md): Keyword strings used to build help text. - [Interface: RouteMap](/stricli/packages/core/interfaces/RouteMap.md): Route map that stores multiple routes. - [Interface: RouteMapBuilderArguments](/stricli/packages/core/interfaces/RouteMapBuilderArguments.md): Type Parameters - [Interface: ScannerConfiguration](/stricli/packages/core/interfaces/ScannerConfiguration.md): Configuration for controlling the behavior of the command and argument scanners. - [Interface: StricliProcess](/stricli/packages/core/interfaces/StricliProcess.md): Simple interface that mirrors NodeJS.Process but only requires the minimum API required by Stricli. - [Type Alias: Aliases](/stricli/packages/core/type-aliases/Aliases.md): Aliases\: Readonly\\>\> - [Type Alias: ApplicationFlagFunction()](/stricli/packages/core/type-aliases/ApplicationFlagFunction.md): ApplicationFlagFunction\: (this, app, args) => void \| Promise\ - [Type Alias: BaseArgs](/stricli/packages/core/type-aliases/BaseArgs.md): BaseArgs: readonly unknown[] - [Type Alias: BaseFlags](/stricli/packages/core/type-aliases/BaseFlags.md): BaseFlags: Readonly\\> - [Type Alias: CommandBuilderArguments](/stricli/packages/core/type-aliases/CommandBuilderArguments.md): CommandBuilderArguments\: LazyCommandBuilderArguments\ \| LocalCommandBuilderArguments\ - [Type Alias: CommandFunction()](/stricli/packages/core/type-aliases/CommandFunction.md): CommandFunction\: (this, flags, ...args) => void \| Error \| Promise\ - [Type Alias: CommandFunctionLoader()](/stricli/packages/core/type-aliases/CommandFunctionLoader.md): CommandFunctionLoader\: () => Promise\ \| CommandFunction\\> - [Type Alias: DisplayCaseStyle](/stricli/packages/core/type-aliases/DisplayCaseStyle.md): DisplayCaseStyle: "original" \| "convert-camel-to-kebab" - [Type Alias: DocumentedCommand](/stricli/packages/core/type-aliases/DocumentedCommand.md): DocumentedCommand: readonly [string, string] - [Type Alias: EnvironmentVariableName](/stricli/packages/core/type-aliases/EnvironmentVariableName.md): EnvironmentVariableName: "STRICLISKIPVERSIONCHECK" \| "STRICLINO_COLOR" - [Type Alias: FlagParametersForType](/stricli/packages/core/type-aliases/FlagParametersForType.md): FlagParametersForType\ TypedFlagParameter } - [Type Alias: HelpIntegrationConfiguration](/stricli/packages/core/type-aliases/HelpIntegrationConfiguration.md): HelpIntegrationConfiguration: Omit\, "name" \| "aliases" \| "global" \| "run"\> & object - [Type Alias: InputCompletion](/stricli/packages/core/type-aliases/InputCompletion.md): InputCompletion: ArgumentCompletion \| RoutingTargetCompletion - [Type Alias: InputParser()](/stricli/packages/core/type-aliases/InputParser.md): InputParser\: (this, input) => T \| Promise\ - [Type Alias: LifecycleHooks](/stricli/packages/core/type-aliases/LifecycleHooks.md): LifecycleHooks\: ApplicationHooks & CommandHooks\ - [Type Alias: PartialApplicationConfiguration](/stricli/packages/core/type-aliases/PartialApplicationConfiguration.md): PartialApplicationConfiguration Partial\ \} - [Type Alias: ScannerCaseStyle](/stricli/packages/core/type-aliases/ScannerCaseStyle.md): ScannerCaseStyle: "original" \| "allow-kebab-for-camel" - [Type Alias: StricliCommandContextBuilder()](/stricli/packages/core/type-aliases/StricliCommandContextBuilder.md): StricliCommandContextBuilder\: (info) => CONTEXT \| Promise\ - [Type Alias: StricliDynamicCommandContext](/stricli/packages/core/type-aliases/StricliDynamicCommandContext.md): StricliDynamicCommandContext\: ApplicationContext & CONTEXT \| object - [Type Alias: StricliIntegration](/stricli/packages/core/type-aliases/StricliIntegration.md): StricliIntegration\: object - [Type Alias: TypedCommandFlagParameters](/stricli/packages/core/type-aliases/TypedCommandFlagParameters.md): TypedCommandFlagParameters\ TypedCommandFlagParameters_\ - [Type Alias: TypedCommandParameters](/stricli/packages/core/type-aliases/TypedCommandParameters.md): TypedCommandParameters\: TypedCommandFlagParameters\ & TypedCommandPositionalParameters\ - [Type Alias: TypedCommandPositionalParameters](/stricli/packages/core/type-aliases/TypedCommandPositionalParameters.md): TypedCommandPositionalParameters\ TypedCommandPositionalParameters_\ - [Type Alias: TypedFlagParameter](/stricli/packages/core/type-aliases/TypedFlagParameter.md): TypedFlagParameter\ TypedFlagParameterRequired\ - [Type Alias: TypedPositionalParameter](/stricli/packages/core/type-aliases/TypedPositionalParameter.md): TypedPositionalParameter\ RequiredPositionalParameter\ - [Type Alias: TypedPositionalParameters](/stricli/packages/core/type-aliases/TypedPositionalParameters.md): TypedPositionalParameters\ PositionalParameterTuple\\> : PositionalParameterTuple\\> - [Type Alias: VersionInfo](/stricli/packages/core/type-aliases/VersionInfo.md): VersionInfo: object \| object & object - [Type Alias: VersionIntegrationConfiguration](/stricli/packages/core/type-aliases/VersionIntegrationConfiguration.md): VersionIntegrationConfiguration: Omit\, "name" \| "aliases" \| "global" \| "run"\> & object - [Variable: ExitCode](/stricli/packages/core/variables/ExitCode.md): const ExitCode: object - [Variable: text_en](/stricli/packages/core/variables/text_en.md): const text\_en: ApplicationText