Skip to content

feat(exe): add experimental Node.js SEA executable bundling#777

Merged
sxzz merged 4 commits intomainfrom
feat/sea
Feb 22, 2026
Merged

feat(exe): add experimental Node.js SEA executable bundling#777
sxzz merged 4 commits intomainfrom
feat/sea

Conversation

@sxzz
Copy link
Member

@sxzz sxzz commented Feb 21, 2026

  • This PR contains AI-generated code, but I have carefully reviewed it myself. Otherwise, my PR may be closed.

Description

Add exe option to bundle output as a Node.js Single Executable Application (SEA). When enabled, the bundled code is compiled into a standalone executable using Node.js --build-sea (requires Node.js >= 25.5.0).

Core changes:

  • New --exe CLI flag and exe config option with ExeOptions / SeaConfig types
  • Auto-configures defaults when exe is enabled: format defaults to cjs, dts disabled, code splitting disabled
  • Validates single entry point, Node.js version, and runtime (not Bun/Deno)
  • macOS ad-hoc codesigning for Gatekeeper compatibility
  • Refactored ReportPlugin to accept ResolvedConfig directly for reuse
  • Added MB formatting support in formatBytes utility

Documentation:

  • Added --exe to CLI reference (EN + zh-CN)
  • Regenerated API reference (typedoc)
  • Updated skills with new option-exe.md reference

Linked Issues

closes #775, relate #776

Additional context

This feature is marked as experimental. Node.js SEA support via --build-sea is available from Node.js 25.5.0+.

Add `exe` option to bundle output as a Node.js Single Executable Application (SEA).
When enabled, the bundled code is compiled into a standalone executable using `--build-sea`.

- New `--exe` CLI flag and `exe` config option
- Auto-configures format (defaults to CJS), disables dts, disables code splitting
- Supports custom SEA config (code cache, snapshot, assets, etc.)
- macOS ad-hoc codesigning for Gatekeeper compatibility
- Refactored ReportPlugin to accept ResolvedConfig for reuse
- Added MB formatting support in formatBytes utility
- Updated docs (EN/zh-CN CLI reference) and skills
@netlify
Copy link

netlify bot commented Feb 21, 2026

Deploy Preview for tsdown-main ready!

Name Link
🔨 Latest commit 9c0169d
🔍 Latest deploy log https://app.netlify.com/projects/tsdown-main/deploys/6999f34fc743e80008fded86
😎 Deploy Preview https://deploy-preview-777--tsdown-main.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Feb 21, 2026

Open in StackBlitz

tsdown

pnpm add https://pkg.pr.new/tsdown@777 -D
npm i https://pkg.pr.new/tsdown@777 -D
yarn add https://pkg.pr.new/[email protected] -D

create-tsdown

pnpm add https://pkg.pr.new/create-tsdown@777 -D
npm i https://pkg.pr.new/create-tsdown@777 -D
yarn add https://pkg.pr.new/[email protected] -D

tsdown-migrate

pnpm add https://pkg.pr.new/tsdown-migrate@777 -D
npm i https://pkg.pr.new/tsdown-migrate@777 -D
yarn add https://pkg.pr.new/[email protected] -D

commit: 9c0169d

@sxzz sxzz merged commit 418d5b6 into main Feb 22, 2026
17 checks passed
@sxzz sxzz deleted the feat/sea branch February 22, 2026 05:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant