# Bun

> Bun runtime and modern JavaScript backend practices, including Bun-native tooling (bun run/test/build) and PostgreSQL usage guidance. Use when building or reviewing Bun-based services, APIs, scripts, or when Bun-specific workflow questions arise. Use when this capability is needed.

- Skill: `tomevault-io/bun` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add tomevault-io/bun`
- Raw SKILL.md: https://api.skillmd.com/api/skills/tomevault-io/bun/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Productivity
- Author: tomevault-io (https://skillmd.com/u/tomevault-io)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/tomevault-io/bun

---


# Bun Stack Skill

## Default guidance

Apply the rule files in this folder as the source of truth for Bun and PostgreSQL usage.

## Workflow (use this order)

1. Clarify scope: service/API/script/task runner.
2. Prefer Bun-native tooling (`bun install`, `bun run`, `bun test`, `bun build`).
3. Use Bun-native APIs (`Bun.serve`, `Bun.file`, SQLite/Redis) where applicable.
4. Design module boundaries and error handling early.
5. Add tests with `bun test` and include coverage for edge cases.
6. Validate deployment target and build output.

## Review Checklist

- Bun-native tooling used; no unnecessary Node tooling.
- Modern JS/TS patterns (ESM, async/await, private fields) applied.
- Error handling is centralized and user-facing errors are clear.
- IO paths use Bun APIs for performance.
- Tests present and runnable with `bun test`.

## Local Resources

- `bun.mdc` for Bun runtime, tooling, and modern JS/TS backend best practices.
- `postgresql.mdc` for PostgreSQL SQL conventions, performance, and anti-patterns.

---
> Converted and distributed by [TomeVault](https://tomevault.io/claim/heyayushh) — claim your Tome and manage your conversions.
<!-- tomevault:4.0:skill_md:2026-04-13 -->

