$npx skillfedfor your agent

tsdown

tsdown packages your TypeScript and JavaScript code for npm distribution while preserving complete type information. This skill automates the bundling process, ensuring your libraries ship with accurate type declarations for better developer experience and IDE support.

tsdown is a TypeScript library bundler that packages your TypeScript and JavaScript code for npm distribution while preserving complete type information. The skill automates the bundling process, ensuring your libraries ship with accurate type declarations for better developer experience and IDE support.

AI-generated summary based on this skill's SKILL.md

5,665 313 MITupdated by antfu

Decision gist · record as of 2026-06-23

tsdown is a TypeScript library bundler that packages your TypeScript and JavaScript code for npm distribution while preserving complete type information. The skill automates the bundling process, ensuring your libraries ship with accurate type declarations for better developer experience and IDE support.

manual: git clone https://github.com/antfu/skills → cp -r skills/skills/tsdown ~/.claude/skills/tsdown
skills/tsdown/SKILL.md · version 7846f4eb

Use it when

  • Yes, tsdown specializes in bundling TypeScript and JavaScript libraries for npm with type declarations.
  • tsdown can generate multiple output formats (ESM, CJS, IIFE, UMD) from a single source.

Verify before relying

Read SKILL.md below before installing (42 files). Open directory: indexed for reading, not audited.

Same gist for agents: .md · .json

Install

antfu/skills/tsdown · repository language: TypeScript

Open directory. Skills are indexed for reading, not audited. Review a skill's body before installing it.

Frequently asked questions

AI-generated answers based on this skill's SKILL.md and metadata

What is tsdown and what does it do for TypeScript libraries?

tsdown is a TypeScript library bundler that packages your TypeScript and JavaScript code for npm distribution while preserving complete type information. The skill automates the bundling process, ensuring your libraries ship with accurate type declarations for better developer experience and IDE support.

Can tsdown bundle TypeScript libraries for npm with type declarations?

Yes, tsdown specializes in bundling TypeScript and JavaScript libraries for npm with type declarations. It handles the complete packaging workflow, automatically generating and including .d.ts type declaration files so your published library provides full type information to consumers.

What output formats does tsdown support for bundled libraries?

tsdown can generate multiple output formats (ESM, CJS, IIFE, UMD) from a single source, allowing you to distribute your library in the formats your users need without maintaining separate build configurations.

Is tsdown a suitable alternative to tsup for faster bundling?

tsdown is designed as a faster bundler option with minimal configuration changes needed when migrating from tsup. It provides comparable functionality while improving build performance, making it an efficient choice for teams looking to speed up their TypeScript library builds.

Can tsdown be used to build React and Vue component libraries?

Yes, tsdown efficiently builds React, Vue, Solid, and Svelte component libraries. It handles the specific requirements of framework component bundling while maintaining type safety and generating the necessary type declarations for component consumers.

How does tsdown optimize bundle size and performance?

tsdown optimizes bundle size through tree shaking, minification, and dependency control features. These capabilities help reduce your final bundle size while ensuring only necessary code is included in your npm distribution.

SKILL.md

Rendered from the published skill. Quoted content, verbatim.

tsdown - The Elegant Library Bundler

Blazing-fast bundler for TypeScript/JavaScript libraries powered by Rolldown and Oxc.

Runtime Requirement

tsdown requires Node.js 22.18.0 or higher to run (build-time only). However, the bundled output can target much lower Node.js versions via the target option, so libraries built with tsdown are not locked to Node.js 22+ at runtime.

If your package needs to support Node.js 18 / 20:

  • Build with Node.js 22+ in CI (e.g. set target: 'node18' or target: 'node20').
  • Test the built output (or the packed tarball) on the lower Node.js versions you intend to support — e.g. using a matrix job that runs the published package's tests on Node.js 18 / 20 / 22.

When to Use

  • Building TypeScript/JavaScript libraries for npm
  • Generating TypeScript declaration files (.d.ts)
  • Bundling for multiple formats (ESM, CJS, IIFE, UMD)
  • Optimizing bundles with tree

(truncated - see the full file via the links below)

File tree — 15 files
skills/tsdown/LICENSE.md
skills/tsdown/README.md
skills/tsdown/SKILL.md
skills/tsdown/SYNC.md
skills/tsdown/references/README.md
skills/tsdown/references/advanced-benchmark.md
skills/tsdown/references/advanced-ci.md
skills/tsdown/references/advanced-hooks.md
skills/tsdown/references/advanced-plugins.md
skills/tsdown/references/advanced-programmatic.md
skills/tsdown/references/advanced-rolldown-options.md
skills/tsdown/references/guide-getting-started.md
skills/tsdown/references/guide-introduction.md
skills/tsdown/references/guide-migrate-from-tsup.md
skills/tsdown/references/option-cjs-default.md

Let your AI agent find skills like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 56,283 agent skills by what they can do, searchable in plain language.

wish › “Bundle TypeScript/JavaScript libraries for npm with type declarations”

Give your agent the search over MCP, or paste the wish link into any chat. No install? Search from any chat →

Related skills

tsdown
by rolldown · rolldown/tsdown

tsdown is a modern bundler built on Rolldown that streamlines packaging TypeScript and JavaScript libraries for distribution. It combines fast build performance with automatic declaration file generation, making it ideal for developers preparing libraries for npm publication.

MITupdated Jul 2026
★ 4,183repo stars
tsdown
by hairyf · hairyf/skills

tsdown is a bundling tool designed to package TypeScript and JavaScript libraries for npm distribution with support for multiple output formats. It simplifies the build process by offering flexible configuration options tailored to modern web development workflows.

MITupdated Jun 2026
★ 24repo stars
tsdown
by sanity-io · sanity-io/next-sanity

tsdown handles the complexities of preparing TypeScript and JavaScript packages for npm distribution across multiple module formats. It automates bundling, format generation, and output optimization so you can focus on writing code rather than build configuration.

MITupdated Jul 2026
★ 951repo stars
Ts Sdk Author
by mindfold-ai · mindfold-ai/Trellis

Ts Sdk Author provides a robust framework for building and organizing TypeScript SDKs from the ground up. This agent harness accelerates SDK scaffolding, letting you focus on implementation details rather than boilerplate setup. Ideal for developers who need production-ready TypeScript SDK foundations quickly.

AGPL-3.0updated Jul 2026
★ 13,222repo stars
Tsdown
by oakoss · oakoss/agent-skills

Tsdown streamlines the process of acquiring TypeScript files on demand, giving developers a straightforward way to handle remote file retrieval in their workflows. Whether you're building automation scripts or managing dependencies, this tool integrates seamlessly into your development pipeline.

no license declared → metadata onlyupdated Mar 2026
★ 13repo stars
tsdown-migrate
by rolldown · rolldown/tsdown

This skill guides you through converting an existing tsup-based build setup to tsdown, Rolldown's elegant library bundler. It provides comprehensive option mappings and automated config transformation to ensure your project transitions smoothly while maintaining build performance and output quality.

MITupdated Jul 2026
★ 4,183repo stars

More skills Ts Library (unlicensed) · arch-tsdown (MIT) · antfu (MIT) · antfu (MIT) · monorepo-management (MIT) · turborepo (MIT)

Tags
build-toolmodule-bundlingtype-safetyperformance-focusedmulti-format-outputtree-shakingcomponent-librariesmonorepo-supportcli-toolsource-maps