@standardagents/builder 0.12.3 → 0.12.5
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/index.js +18 -0
- package/dist/index.js.map +1 -1
- package/dist/plugin.js +18 -0
- package/dist/plugin.js.map +1 -1
- package/package.json +4 -4
package/dist/plugin.js
CHANGED
|
@@ -4859,6 +4859,14 @@ function agentbuilder(options = {}) {
|
|
|
4859
4859
|
return {
|
|
4860
4860
|
// Set publicDir to builder's client assets so Cloudflare plugin preserves assets config
|
|
4861
4861
|
publicDir: fs2__default.existsSync(builderClientDir) ? builderClientDir : void 0,
|
|
4862
|
+
build: {
|
|
4863
|
+
rollupOptions: {
|
|
4864
|
+
// fsevents is a macOS-only native module dynamically imported by rollup's
|
|
4865
|
+
// file watcher. Rollup is pulled in by the packing system but fsevents is
|
|
4866
|
+
// never needed at runtime. Must be externalized for Linux CI builds.
|
|
4867
|
+
external: ["fsevents"]
|
|
4868
|
+
}
|
|
4869
|
+
},
|
|
4862
4870
|
optimizeDeps: {
|
|
4863
4871
|
// Exclude our packages from pre-bundling - they contain cloudflare:workers imports
|
|
4864
4872
|
// that cannot be resolved during dependency optimization
|
|
@@ -4924,6 +4932,16 @@ function agentbuilder(options = {}) {
|
|
|
4924
4932
|
...config.optimizeDeps.include || [],
|
|
4925
4933
|
...depsToInclude.filter((dep) => !config.optimizeDeps?.include?.includes(dep))
|
|
4926
4934
|
];
|
|
4935
|
+
config.build = config.build || {};
|
|
4936
|
+
config.build.rollupOptions = config.build.rollupOptions || {};
|
|
4937
|
+
const existing = config.build.rollupOptions.external;
|
|
4938
|
+
if (Array.isArray(existing)) {
|
|
4939
|
+
if (!existing.includes("fsevents")) existing.push("fsevents");
|
|
4940
|
+
} else if (typeof existing === "string") {
|
|
4941
|
+
config.build.rollupOptions.external = [existing, "fsevents"];
|
|
4942
|
+
} else if (!existing) {
|
|
4943
|
+
config.build.rollupOptions.external = ["fsevents"];
|
|
4944
|
+
}
|
|
4927
4945
|
},
|
|
4928
4946
|
resolveId(id) {
|
|
4929
4947
|
if (id === VIRTUAL_TOOLS_ID) {
|