Skip to content

Commit 8b3d15f

Browse files
bkeepersCopilot
andcommitted
Fix SEA build: bundle all dependencies with deps.alwaysBundle
tsdown's DepPlugin externalizes any package listed in package.json dependencies by default. For a SEA binary every dependency must be bundled into the single output file, so override this with deps.alwaysBundle: () => true. The previous deps.skipNodeModulesBundle: false was a no-op — that flag only controls automatic externalization of node_modules that are NOT production deps, and was already false by default. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent b47cd95 commit 8b3d15f

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

packages/cli/tsdown.sea.config.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,9 @@ export default defineConfig({
66
entry: ["./src/index.ts"],
77
platform: "node",
88
deps: {
9-
skipNodeModulesBundle: false,
9+
// SEA needs everything bundled — override the default behavior that
10+
// externalizes packages listed in package.json dependencies.
11+
alwaysBundle: () => true,
1012
},
1113
exe: {
1214
fileName: "neaps",

0 commit comments

Comments
 (0)