Bun Typescript starter template
use with bun create:
bun create WhizUs/bun-starter
Optionally specify a name for the destination folder. If no destination is specified, the repo name will be used.
bun create WhizUs/bun-starter my-bun-project
- pre-configured lint and editorconfig
- biome
- lint code
- format code
- biome
- pre-commit hook using husky
- mise-en-place config
- to get current version of bun automatically
- run
bun install
bun dev
starts a local dev server in watch mode
Write all your tests in the folder tests
.
There should be one testfile per ts
file. A test file should be named like this: <filename>.test.ts
.
The folder structure should be as in src
.
- run all tests:
bun test
- run all test in watch mode:
bun test-watch
- run tests for a single test file:
bun test <filename incl path>
- run tests for a single test file in watch mode:
bun test --watch <filename incl path>
We use conventional commits for our commit messages.
before you commit make sure you run and check following:
bun lint
- check code style (bun lint-fix
to fix automatically)bun ec
- check editorconfigbun test
- check if your tests pass
Super fast javascript runtime.
TypeScript framework supercharged by Bun with End-to-End Type Safety, unified type system and outstanding developer experience