-
Beta Was this translation helpful? Give feedback.
Answered by
kanopa
Aug 16, 2022
Replies: 1 comment 6 replies
-
I guess we need sth like this and call it on onExecuteDone const processFederationResult = (processedResult) => {
// if _entities exists in data it is federation response
if ('_entities' in processedResult?.data) {
// need to add all representations to identifier for invalidation federation responses
onExecuteParams.args.variableValues.representations?.forEach(({ __typename: typename, id }) => {
identifier.set(`${typename}:${id}`, { typename, id });
})
}
} |
Beta Was this translation helpful? Give feedback.
6 replies
Answer selected by
n1ru4l
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I guess we need sth like this and call it on onExecuteDone