From c1db00b7d1c21338386a6f04d755dc38c355b05e Mon Sep 17 00:00:00 2001 From: Mihai Agape Date: Fri, 23 Oct 2026 15:31:46 +0200 Subject: [PATCH] feat(apollo-react): deprecate exclude runtime constraints in favor of include A node with { exclude: [...] } is available in every runtime added later, so each new runtime forces a manifest update to opt the node back out. The exclude variant is now marked @deprecated and the schema docs point to include. Existing manifests still parse. Co-Authored-By: Claude Opus 5.5 --- .../src/canvas/schema/node-definition/node-manifest.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/packages/apollo-react/src/canvas/schema/node-definition/node-manifest.ts b/packages/apollo-react/src/canvas/schema/node-definition/node-manifest.ts index e9a1bc7a27..eb12ec932c 100644 --- a/packages/apollo-react/src/canvas/schema/node-definition/node-manifest.ts +++ b/packages/apollo-react/src/canvas/schema/node-definition/node-manifest.ts @@ -101,11 +101,17 @@ export const nodeDisplayManifestSchema = z.object({ * Runtime constraints for the node. * * - `{ include: [...] }` — available exclusively in the listed runtimes - * - `{ exclude: [...] }` — available in all runtimes except the listed ones + * - `{ exclude: [...] }` — deprecated, use `include` */ export const nodeRuntimeConstraintsManifestSchema = z.union([ z.object({ include: z.array(z.string()) }), - z.object({ exclude: z.array(z.string()) }), + z.object({ + /** + * @deprecated Use `include`. An excluded node is available in every runtime added later, + * so each new runtime forces a manifest update to opt the node back out. + */ + exclude: z.array(z.string()), + }), ]); /**