Boost Library

website·Indexed 31 days ago

https://boostlib.dev/

A collection of type-safe utilities for Node.js and React, featuring tools for CLI development, terminal management, pipeline processing, plugin architectures, event systems, and internationalization (translate). Includes specialized packages such as @boost/args for argument parsing and @boost/internal for scoped error handling.

Tokens
79.8K
Snippets
599
Records
860
Agent score
52%

What's inside Boost

  1. Overview of @boost/translate features

    @boost/translate is a wrapper for the i18next library designed to simplify server-side translations. Key features include:

    • Isolated translator instances.
    • Namespace-aware resource bundles.
    • Automatic locale detection via command line options or the operating system.
    • Support for multiple resource file types: JavaScript, JSON, and YAML.
    • Support for message interpolation, pluralization, and nesting.
  2. Overview of @boost/debug features

    @boost/debug is a lightweight debugging and crash reporting wrapper around the debug library. Key features include:

    • Isolated and namespaced debugger instances controlled by the DEBUG environment variable.
    • A crash reporter that logs system information, running processes, programming languages, and binary versions.
    • Support for both standard and verbose debug output.
    • Ability to toggle debugging during runtime.
  3. Overview of @boost/pipeline features

    @boost/pipeline provides a framework for processing data through stages. Key features include:

    • Support for both parallel and serial processing pipelines.
    • Two types of work units: tasks and routines.
    • Pooling and aggregated implementations for complex or computationally heavy logic.
    • Contextually aware executions.
  4. Overview of @boost/args argument parsing

    @boost/args is a convention-based argument parsing and formatting library with strict validation checks. It is designed for parsing arguments (like those from process.argv) but is not a full command-line interface (CLI) framework.
  5. Overview of @boost/event features

    The @boost/event library provides a strict event system with the following capabilities:

    • Type-Safety: Isolated event instances ensure arguments are correctly typed.
    • Emitter Patterns: Supports four distinct event types: standard, bail, concurrent, and waterfall.
    • Targeted Emits: Supports listener scopes for precise event emission.
  6. Overview of @boost/config features

    @boost/config provides the following capabilities for configuration management:

    • File Discovery: Loads root configs (e.g., .config/<name>.js) and branch configs (e.g., .<name>.js).
    • Ignore Files: Loads ignore files using the .<name>ignore convention.
    • Format Support: Supports .js, .cjs, .mjs, .json, and .yaml files.
    • Hierarchical Overrides: Supports environment-based and root-level overrides, as well as extending from other configuration files.
    • Efficiency: Traverses branch folders up the tree and caches finder results.
    • Processing: Includes custom key-value setting processors.
  7. Overview of SerialPipeline

    The SerialPipeline class is used to run and process work units synchronously. It extends the base Pipeline class and is a parent to WaterfallPipeline. It allows developers to chain work units where the output of one unit becomes the input for the next.
  8. Overview of @boost/cli features

    The @boost/cli library provides several advanced features for building terminal applications:

    • Argument Support: Integration with @boost/args for commands, options, flags, and parameters.
    • Command Definitions: Supports declarative commands (via decorators) or imperative commands (via static properties), as well as shorthand proxy commands.
    • UI Rendering: Uses React and Ink to render interfaces at 16 FPS, with support for simple string output.
    • UX Enhancements: Automatic generation of help, usage, error, and index menus; console log buffering to prevent render tearing.
    • Extensibility: Middleware support for modifying argv or parsed arguments, and customizable terminal themes.
  9. Overview of the Path class

    The Path class is an immutable utility used for operating on file system paths. It automatically normalizes path separators based on the host operating system: using / on Linux and MacOS, and \ on Windows. It implements the Pathable interface and is extended by VirtualPath.
  10. Use the Transport class to implement custom log outputs

    The Transport class is an abstract base class used to define how log messages are written to a destination. It implements the Transportable interface and is extended by specific implementations such as ConsoleTransport, FileTransport, and StreamTransport.
  11. Command class overview and hierarchy

    The Command class is the primary building block for creating CLI commands in Boost. It extends CommandManager<Options> and implements the Commandable<O, P> interface. It handles argument parsing, option validation, and command execution.
  12. Use the ModulePath class for Node.js module path operations

    The ModulePath class is an immutable utility used to operate on Node.js module IDs, names, and paths. It implements the Pathable interface.