3 ms·
Actually you can directly read and write the cache with the readQuery command. You can see it here https://www.apollographql.com/docs/react/advanced/caching.htm
by knlam 8y ago
Actually you can directly read and write the cache with the readQuery command. You can see it here https://www.apollographql.com/docs/react/advanced/caching.html#direct https://www.apollographql.com/docs/react/advanced/caching.ht...
- ryanar 8y agothis doesn't work when you have a query with any sort of variables. for instance if a query that returns SortBy "Name" and the user changes the sort to be "Email", now you have two queries you would need to call readQuery on and update, and that means you need to track all query variables and all affected queries for a delete. It just doesn't work. See https://github.com/apollographql/apollo-feature-requests/issues/33#issuecomment-425171570 https://github.com/apollographql/apollo-feature-requests/iss... and the numerous threads of people expounding on this issue.