gentleeduck/duck-ui / .claude/skills/tsdown
tsdown
VerifiedBundle TypeScript and JavaScript libraries with blazing-fast speed powered by Rolldown. Use when building libraries, generating type declarations, bundling for multiple formats, or migrating from tsup.
references/guide-introduction.md
View on GitHub# Introduction
**tsdown** is _The Elegant Library Bundler_ — a fast, simple bundler for TypeScript and JavaScript libraries powered by Rolldown (Rust-based).
## Why tsdown?
Built on [Rolldown](https://rolldown.rs), tsdown provides a complete out-of-the-box solution for library authors:
- **Simplified Configuration**: Sensible defaults for library development, minimal boilerplate
- **Library-Specific Features**: Auto TypeScript declarations, multiple output formats, package validation
- **Future-Ready**: Official Rolldown project, foundation for Rolldown Vite's Library Mode
## Plugin Ecosystem
Supports the full Rolldown plugin ecosystem plus most Rollup plugins. See [Plugins](advanced-plugins.md).
## What Can It Bundle?
- **TypeScript/JavaScript**: `.ts`, `.js` with modern syntax
- **TypeScript Declarations**: Auto-generate `.d.ts` files
- **Multiple Formats**: `esm`, `cjs`, `iife`, `umd`
- **Assets**: `.json`, `.wasm`, CSS files
- Built-in tree shaking, minification, and source maps
## Key Differences from Rolldown
tsdown wraps Rolldown with library-specific features:
- Auto-external `dependencies`, `peerDependencies`, and `optionalDependencies` from `package.json`
- DTS generation
- `package.json` exports field generation
- Watch mode with keyboard shortcuts
- CSS preprocessing pipeline
- Executable bundling (SEA)
## Prior Arts
Inspired by: Rollup, esbuild, tsup, unbuild. Powered by Rolldown.
## Related
- [Getting Started](guide-getting-started.md) - Installation and first build
- [Migrate from tsup](guide-migrate-from-tsup.md) - Migration guide
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| receiving-code-reviewobra/superpowersUse when receiving code review feedback, before implementing suggestions, especially if feedback seems unclear or technically questionable - requires technical rigor and verification, not performative agreement or blind implementation | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| requesting-code-reviewobra/superpowersUse when completing tasks, implementing major features, or before merging to verify work meets requirements | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| using-git-worktreesobra/superpowersUse when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallback | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| verification-before-completionobra/superpowersUse when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |