bun-types
Type definitions and documentation for Bun, an incredibly fast JavaScript runtime
Last updated 2 months ago by jarred .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install bun-types 
SYNC missed versions from official npm registry.

TypeScript types for Bun

Logo

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

Installation

Install the @types/bun npm package:

# yarn/npm/pnpm work too
# @types/bun is an ordinary npm package
bun add -D @types/bun

That's it! VS Code and TypeScript automatically load @types/* packages into your project, so the Bun global and all bun:* modules should be available immediately.

Contributing

The @types/bun package is a shim that loads bun-types. The bun-types package lives in the Bun repo under packages/bun-types.

To add a new file, add it under packages/bun-types. Then add a triple-slash directive pointing to it inside ./index.d.ts.

+ /// <reference path="./newfile.d.ts" />
bun build

Current Tags

  • 1.3.11-canary.20260304T141819                                ...           canary (a month ago)
  • 1.3.10                                ...           latest (2 months ago)

1214 Versions

Downloads
Today 0
This Week 1
This Month 4
Last Day 0
Last Week 92
Last Month 1,143
Dependencies (1)
Dev Dependencies (0)
None
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |