@standardagents/builder 0.12.5 → 0.12.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/built-in-routes.js +3779 -3712
- package/dist/built-in-routes.js.map +1 -1
- package/dist/index.js +26 -7
- package/dist/index.js.map +1 -1
- package/dist/plugin.js +26 -7
- package/dist/plugin.js.map +1 -1
- package/package.json +4 -4
package/dist/plugin.js
CHANGED
|
@@ -4861,10 +4861,19 @@ function agentbuilder(options = {}) {
|
|
|
4861
4861
|
publicDir: fs2__default.existsSync(builderClientDir) ? builderClientDir : void 0,
|
|
4862
4862
|
build: {
|
|
4863
4863
|
rollupOptions: {
|
|
4864
|
-
//
|
|
4865
|
-
//
|
|
4866
|
-
//
|
|
4867
|
-
|
|
4864
|
+
// The packing system dynamically imports rollup, typescript, and related
|
|
4865
|
+
// plugins for the CLI `pack` command. These are never needed at runtime
|
|
4866
|
+
// in Cloudflare Workers and must be externalized:
|
|
4867
|
+
// - rollup/typescript/fsevents contain Node.js-only APIs (__filename, fs)
|
|
4868
|
+
// - fsevents is macOS-only and doesn't exist on Linux CI
|
|
4869
|
+
external: [
|
|
4870
|
+
"rollup",
|
|
4871
|
+
"@rollup/plugin-commonjs",
|
|
4872
|
+
"@rollup/plugin-node-resolve",
|
|
4873
|
+
"rollup-plugin-esbuild",
|
|
4874
|
+
"fsevents",
|
|
4875
|
+
"typescript"
|
|
4876
|
+
]
|
|
4868
4877
|
}
|
|
4869
4878
|
},
|
|
4870
4879
|
optimizeDeps: {
|
|
@@ -4932,15 +4941,25 @@ function agentbuilder(options = {}) {
|
|
|
4932
4941
|
...config.optimizeDeps.include || [],
|
|
4933
4942
|
...depsToInclude.filter((dep) => !config.optimizeDeps?.include?.includes(dep))
|
|
4934
4943
|
];
|
|
4944
|
+
const packingDeps = [
|
|
4945
|
+
"rollup",
|
|
4946
|
+
"@rollup/plugin-commonjs",
|
|
4947
|
+
"@rollup/plugin-node-resolve",
|
|
4948
|
+
"rollup-plugin-esbuild",
|
|
4949
|
+
"fsevents",
|
|
4950
|
+
"typescript"
|
|
4951
|
+
];
|
|
4935
4952
|
config.build = config.build || {};
|
|
4936
4953
|
config.build.rollupOptions = config.build.rollupOptions || {};
|
|
4937
4954
|
const existing = config.build.rollupOptions.external;
|
|
4938
4955
|
if (Array.isArray(existing)) {
|
|
4939
|
-
|
|
4956
|
+
for (const dep of packingDeps) {
|
|
4957
|
+
if (!existing.includes(dep)) existing.push(dep);
|
|
4958
|
+
}
|
|
4940
4959
|
} else if (typeof existing === "string") {
|
|
4941
|
-
config.build.rollupOptions.external = [existing,
|
|
4960
|
+
config.build.rollupOptions.external = [existing, ...packingDeps];
|
|
4942
4961
|
} else if (!existing) {
|
|
4943
|
-
config.build.rollupOptions.external = [
|
|
4962
|
+
config.build.rollupOptions.external = [...packingDeps];
|
|
4944
4963
|
}
|
|
4945
4964
|
},
|
|
4946
4965
|
resolveId(id) {
|