@particle-academy/fancy-flow 0.30.0 → 0.32.0
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/engine.cjs +17 -8
- package/dist/engine.cjs.map +1 -1
- package/dist/engine.d.cts +20 -9
- package/dist/engine.d.ts +20 -9
- package/dist/engine.js +17 -8
- package/dist/engine.js.map +1 -1
- package/dist/index.cjs +12 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +13 -1
- package/dist/index.d.ts +13 -1
- package/dist/index.js +12 -2
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/engine.cjs
CHANGED
|
@@ -477,7 +477,7 @@ function validateAliases(aliases2, problems) {
|
|
|
477
477
|
}
|
|
478
478
|
function validateRuntimes(runtimes, problems) {
|
|
479
479
|
if (typeof runtimes !== "object" || runtimes === null || Array.isArray(runtimes)) {
|
|
480
|
-
problems.push(err("runtimes", "Required \u2014 an object of runtime id to {
|
|
480
|
+
problems.push(err("runtimes", "Required \u2014 an object of runtime id to { files, engine }."));
|
|
481
481
|
return;
|
|
482
482
|
}
|
|
483
483
|
const entries = Object.entries(runtimes);
|
|
@@ -487,17 +487,26 @@ function validateRuntimes(runtimes, problems) {
|
|
|
487
487
|
}
|
|
488
488
|
for (const [runtime, spec] of entries) {
|
|
489
489
|
if (typeof spec !== "object" || spec === null || Array.isArray(spec)) {
|
|
490
|
-
problems.push(err(`runtimes.${runtime}`, "Must be an object of {
|
|
490
|
+
problems.push(err(`runtimes.${runtime}`, "Must be an object of { files, engine }."));
|
|
491
491
|
continue;
|
|
492
492
|
}
|
|
493
493
|
const s = spec;
|
|
494
|
-
const
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
494
|
+
const files = Array.isArray(s.files) ? s.files : null;
|
|
495
|
+
if (!files || files.length === 0 || files.some((f) => typeof f !== "string" || f.trim() === "")) {
|
|
496
|
+
problems.push(
|
|
497
|
+
err(
|
|
498
|
+
`runtimes.${runtime}`,
|
|
499
|
+
"Needs `files` \u2014 the node source directories this runtime's backend lives in, relative to the node."
|
|
500
|
+
)
|
|
501
|
+
);
|
|
498
502
|
}
|
|
499
|
-
if (
|
|
500
|
-
problems.push(
|
|
503
|
+
if (s.entry !== void 0 || s.package !== void 0) {
|
|
504
|
+
problems.push(
|
|
505
|
+
err(
|
|
506
|
+
`runtimes.${runtime}`,
|
|
507
|
+
"`entry` / `package` are gone \u2014 nodes are copied into a project, not installed from a registry. Declare `files` instead."
|
|
508
|
+
)
|
|
509
|
+
);
|
|
501
510
|
}
|
|
502
511
|
if (typeof s.engine !== "string" || s.engine.trim() === "") {
|
|
503
512
|
problems.push(
|