Make local graph execution optional across composed packages
This commit is contained in:
@@ -250,10 +250,10 @@ export async function compileQuery(
|
||||
const getter = member.operations.find(
|
||||
(operation) => operation.displayName === (member.kind === "value" ? "get" : "resolve"),
|
||||
);
|
||||
if (getter?.execution?.kind !== "snapshot" || !getter.execution.targets.includes("browser"))
|
||||
if (getter?.execution?.kind !== "snapshot")
|
||||
fail(
|
||||
"QUERY_LOCAL_DEPENDENCY",
|
||||
`Local query requires a browser snapshot getter for ${contract.displayName}.${name}; split the remote field or move the query to the server`,
|
||||
`Local query requires a graph snapshot getter for ${contract.displayName}.${name}; split the remote field or move the query to the server`,
|
||||
node,
|
||||
);
|
||||
if (member.queryRead.execution === "rpc-permitted")
|
||||
|
||||
Reference in New Issue
Block a user