Skip to content

Commit 4e26407

Browse files
chore: revert browser-bundle external workaround (fixed upstream by typescript-sdk#1871)
1 parent b845fd7 commit 4e26407

6 files changed

Lines changed: 0 additions & 8 deletions

File tree

build.bun.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ function buildJs(
3434
// zod is a peerDependency — keep it external so consumers share a single
3535
// zod instance (instanceof ZodError / schema.extend() break with duplicate copies).
3636
const PEER_EXTERNALS = ["@modelcontextprotocol/client", "@modelcontextprotocol/server", "zod"];
37-
const NODE_EXTERNALS = ["node:*", "child_process", "cross-spawn", "fs", "path", "os", "stream", "events", "util", "crypto", "http", "https", "net", "url", "buffer", "process"];
3837

3938
await Promise.all([
4039
buildJs("src/app.ts", {
@@ -44,7 +43,6 @@ await Promise.all([
4443
buildJs("src/app.ts", {
4544
outdir: "dist/src",
4645
naming: { entry: "app-with-deps.js" },
47-
external: NODE_EXTERNALS,
4846
}),
4947
buildJs("src/app-bridge.ts", {
5048
outdir: "dist/src",
@@ -58,7 +56,6 @@ await Promise.all([
5856
outdir: "dist/src/react",
5957
external: ["react", "react-dom"],
6058
naming: { entry: "react-with-deps.js" },
61-
external: NODE_EXTERNALS,
6259
}),
6360
buildJs("src/server/index.ts", {
6461
outdir: "dist/src/server",

docs/quickstart.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,6 @@ export default defineConfig({
138138
minify: !isDevelopment,
139139

140140
rollupOptions: {
141-
external: (id) => /^node:|^(child_process|cross-spawn|fs|path|os|crypto|stream|util|net|http|https|events|url|buffer|process)$/.test(id),
142141
input: INPUT,
143142
},
144143
outDir: "dist",

examples/basic-host/vite.config.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ export default defineConfig({
1616
cssMinify: !isDevelopment,
1717
minify: !isDevelopment,
1818
rollupOptions: {
19-
external: (id) => /^node:|^(child_process|cross-spawn|fs|path|os|crypto|stream|util|net|http|https|events|url|buffer|process)$/.test(id),
2019
input: INPUT,
2120
},
2221
outDir: `dist`,

examples/basic-server-react/vite.config.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ export default defineConfig({
1717
minify: !isDevelopment,
1818

1919
rollupOptions: {
20-
external: (id) => /^node:|^(child_process|cross-spawn|fs|path|os|crypto|stream|util|net|http|https|events|url|buffer|process)$/.test(id),
2120
input: INPUT,
2221
},
2322
outDir: "dist",

examples/basic-server-vanillajs/vite.config.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ export default defineConfig({
1616
minify: !isDevelopment,
1717

1818
rollupOptions: {
19-
external: (id) => /^node:|^(child_process|cross-spawn|fs|path|os|crypto|stream|util|net|http|https|events|url|buffer|process)$/.test(id),
2019
input: INPUT,
2120
},
2221
outDir: "dist",

examples/quickstart/vite.config.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ export default defineConfig({
2323
minify: !isDevelopment,
2424

2525
rollupOptions: {
26-
external: (id) => /^node:|^(child_process|cross-spawn|fs|path|os|crypto|stream|util|net|http|https|events|url|buffer|process)$/.test(id),
2726
input: INPUT,
2827
},
2928
outDir: "dist",

0 commit comments

Comments
 (0)