@types/bun
.
terminal
Bun
global in your TypeScript files without seeing errors in your editor.
Suggested compilerOptions
Bun supports things like top-level await, JSX, and extensioned .ts
imports, which TypeScript doesn’t allow by default. Below is a set of recommended compilerOptions
for a Bun project, so you can use these features without seeing compiler warnings from TypeScript.
tsconfig.json
bun init
in a new directory, this tsconfig.json
will be generated for you. (The stricter flags are disabled by default.)
terminal