Nocturnal Pumpkin Maelstrom

    bun-types
    TypeScript icon, indicating that this package has built-in type declarations

    0.1.11 • Public • Published

    Bun TypeScript type definitions

    Logo

    These are the type definitions for Bun's JavaScript runtime APIs.

    Installation

    Install the bun-types npm package:

    # yarn/npm/pnpm work too, "bun-types" is an ordinary npm package
    bun add bun-types

    Usage

    Add this to your tsconfig.json or jsconfig.json:

    {
      "compilerOptions": {
        "lib": ["ESNext"],
        "module": "esnext",
        "target": "esnext",
        // "bun-types" is the important part
        "types": ["bun-types"]
      }
    }

    Contributing

    bun-types is generated via ./bundle.ts.

    Adding a new file

    1. Add it to ./index.d.ts

    How to generate types.d.ts

    ./bundle.ts merges the types in this folder into a single file.

    To run it:

    bun generate:package

    Generated docs

    📚 See here for docs

    Install

    npm i bun-types

    Homepage

    bun.sh

    DownloadsWeekly Downloads

    2,623

    Version

    0.1.11

    License

    none

    Unpacked Size

    808 kB

    Total Files

    3

    Last publish

    Collaborators

    • jarred