Faʻavaeina o meafaigaluega mo le itulagi
All-in-one JavaScript runtime. Bundler, suʻega taʻalo, ma le pule o paka i se tasi masini vave
Vave 4x i le amataga nai lo Node.js, ma faatinoga e sili ai le vave ua faamalosia e le JavaScriptCore engine
Faʻagaioia faila TypeScript ma JSX i le tuusaunoa e aunoa ma le laasaga compile, ua transpiled i le taimi o le faʻagaioiga
Faapipiiina npm packages i le 30x vave nai lo npm, ma cache o le lalolagi ma le fetaui atoatoa
Faʻapipiʻi poloketi JavaScript/TypeScript i milliseconds ma le vaevaeina o code, tree shaking, ma minification
Test runner vave e fetaui ma API Jest, e aofia ai mocking, snapshots, ma coverage
Runtime, bundler, transpiler, package manager, ma test runner i le tasi binary
# Install Bun
curl -fsSL https://bun.sh/install | bash
# Verify installation
bun --version
# Update Bun to latest version
bun upgradeAmataga vave - Fausia polokalame fou:# Initialize new project
bun init
# Run TypeScript/JavaScript file
bun run index.ts
# Install dependencies
bun install
# Run with watch mode (hot reload)
bun --watch run index.tsFaagaioia se polokalame Node.js o loʻo iai:# Install dependencies (much faster than npm)
bun install
# Run with Bun runtime instead of Node
bun run start
# Or use as drop-in Node replacement
bun run dev
{
"scripts": {
"dev": "bun --watch run src/index.ts",
"build": "bun build src/index.ts --outdir dist",
"test": "bun test",
"start": "bun run dist/index.js"
}
}Bundling ma Bun:# Bundle for production
bun build ./src/index.ts --outdir ./dist --target browser
# Bundle with minification
bun build ./src/index.ts --outdir ./dist --minify
# Bundle for Node.js target
bun build ./src/index.ts --outdir ./dist --target nodeSuʻesuʻega:# Run all tests
bun test
# Run specific test file
bun test auth.test.ts
# Watch mode
bun test --watch
# With coverage
bun test --coverageFesuiaiga o le Environment:.envprocess.env poʻo Bun.envFaʻaauau i minute ma la matou faiga faʻatino faigofie VPS
Faʻaaogaina i le tusa ma le 2 minute • Full root access • Support by ticket and email