Skip to content
Back to skills

Esbuild

ASecurity

esbuild — ultra-fast bundler with JSX/TS transforms, plugins, watch, serve, code splitting.

  • 47 stars
  • 0 votes
  • 0 copies
  • 4 views
  • Added September 12, 2026
developmenttypescriptreactnodeapi

Works with

  • api

Security analysis

A100/100

Scanned September 12, 2026

npx -y skills add skeletorflet/opencode-supreme-setup --skill esbuild --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Esbuild?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Esbuild
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/skeletorflet-esbuild/badge)](https://www.skillsdirectory.com/skills/skeletorflet-esbuild)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: esbuild
description: esbuild — ultra-fast bundler with JSX/TS transforms, plugins, watch, serve, code splitting.
---

## esbuild

### Bundling
- `require('esbuild').build({ entryPoints: ['src/index.ts'], outfile: 'dist/bundle.js', bundle: true })`.
- `format: 'esm' | 'cjs' | 'iife'` — output module format.
- `platform: 'browser' | 'node' | 'neutral'` — target environment defaults.
- External: `external: ['react', 'react-dom']` — exclude from bundle.

### Transforms
- JSX: automatic runtime (`"jsx": "automatic"`) or classic.
- TypeScript: strips types, no type-checking — use `tsc --noEmit` separately.
- Target: `target: 'es2020'` — downlevel syntax to specified JS version.
- JSX transform standalone: `transformSync('<div/>', { loader: 'jsx' })`.

### Plugins
- Plugin API: `{ name: 'my-plugin', setup(build) { build.onResolve(...) / onLoad(...) } }`.
- Virtual modules: `onLoad({ filter: /.*/ }, () => ({ contents: '...', loader: 'ts' }))`.
- Popular: `esbuild-plugin-inline-import`, `esbuild-plugin-html`, `esbuild-sass-plugin`.
- Namespace isolation: `namespace: 'http'` for custom URL resolution.

### Watch & Serve
- `watch: { onRebuild(err, result) { ... } }` — file watcher + rebuild.
- `serve({ servedir: 'dist', port: 8000 })` — dev server with live reload.
- `context = await build(...)` then `context.watch()` / `context.serve()` / `context.rebuild()`.
- `context.dispose()` — clean up watchers and servers.

### Minification & Code Splitting
- `minify: true` / `minifyWhitespace: true` / `minifySyntax: true` / `minifyIdentifiers: true`.
- `splitting: true` + `format: 'esm'` — shared chunks for code splitting.
- `treeShaking: true` — remove unused exports (default for bundle: true).
- `sourcemap: true | 'inline' | 'external'` — control source map generation.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.