# All channels
# Apollo Angular
# Apollo Android
# Apollo Client
# Apollo Federation
# Apollo iOS
# Apollo Link
# Apollo Link Rest
# Local State
# Apollo Platform
# Apollo Server
# Apollo Tooling
# GraphQL Tools
# React Apollo
# Vue Apollo
Do subscriptions update cache automatically?
I am using subscriptions in a component. I used to have this subscription in my component As you can see, it just waits for updates on the application and if there are any updates I update the cache. The code is working fine but I wanted to improve it. As I am only updating the…
Replacing Redux - how to share request state to non-descendant component?
I'm trying to adopt Apollo in a React application that currently uses Redux for state management. I know that many people use Apollo's cache as a global application state, instead of using Redux. I don't know how to deal with this use case: • In Component A, a user clicks a…
Can `<Query>` ever return `data==undefined`?
According to the docs at https://www.apollographql.com/docs/react/api/react-apollo/?origin_team=T029GG40X#render-prop-function, QueryResult.data defaults to undefined. But in our testing (and year+ of experience), we've never actually seen the value undefined; even when…
(Resolved) Change state from useMutation result
I'd like to navigate back* after a mutation result comes back, but doing it in the way suggested in the docs doesn't seem to work, since you can't update state within the render function: ... in a functional component ... const [doMutation, doMutationResult] =…
Testing components that use getQuery hook?
Having trouble getting tests for components that use the useQuery hook to pass. Here is a Stack Overflow post w/ my current attempt at setting up the tests --> https://stackoverflow.com/questions/57060842/example-of-how-to-test-a-component-that-uses-usequery The data returned by…
Correct pattern for updating props from router properties?
I have a UI that is navigating through a collection of items by using the URL pattern, like this: This triggers a render function that executes a query to get a new item object, and then passes that as a prop to an inner component, like this: This almost works. When I change the…