Skip to content
Discussion options

You must be logged in to vote

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 });
                    })
                }
            }

Replies: 1 comment 6 replies

Comment options

You must be logged in to vote
6 replies
@kanopa
Comment options

@n1ru4l
Comment options

@n1ru4l
Comment options

@n1ru4l
Comment options

@n1ru4l
Comment options

Answer selected by n1ru4l
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants