Skip to content

Commit 2dddfc4

Browse files
committed
fix: NodeJS bundle invalid
Signed-off-by: Gordon Smith <GordonJSmith@gmail.com>
1 parent 0d1e42f commit 2dddfc4

2 files changed

Lines changed: 12 additions & 3 deletions

File tree

packages/comms/esbuild.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@ import { nodeTpl, nodeBoth } from "@hpcc-js/esbuild-plugins";
22

33
// config ---
44
await Promise.all([
5-
nodeBoth("src/index.node.ts", "dist/node/index", { packages: "bundle" }),
6-
nodeTpl("utils/index.ts", "lib-esm/index")
5+
nodeBoth("src/index.node.ts", "dist/node/index", {
6+
packages: "external",
7+
external: ["node:*"]
8+
}),
9+
nodeTpl("utils/index.ts", "lib-esm/index", {
10+
packages: "external",
11+
external: ["node:*"]
12+
})
713
]);

packages/observablehq-compiler/esbuild.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,8 @@ import { nodeBoth } from "@hpcc-js/esbuild-plugins";
22

33
// config ---
44
await Promise.all([
5-
nodeBoth("src/index.node.ts", "dist/node/index")
5+
nodeBoth("src/index.node.ts", "dist/node/index", {
6+
packages: "external",
7+
external: ["node:*"]
8+
})
69
]);

0 commit comments

Comments
 (0)