graphql-kit / graphql-lodash

🛠 Data manipulation for GraphQL queries with lodash syntax
https://apis.guru/graphql-lodash/
MIT License
1.23k stars 48 forks source link

Using graphql-lodash with Apollo mutation refetch queries ? #12

Closed kavink closed 6 years ago

kavink commented 6 years ago

I am trying to figure out how to make graphql-lodash work with Apollo mutation refetch queries . Thoughts ?

IvanGoncharov commented 6 years ago

@kavink You can read about it here: https://blog.apis.guru/query-and-transformation-collocation-with-apollo-client-and-graphql-lodash-9111448ec01b

Or in README: https://github.com/APIs-guru/graphql-lodash#usage-with-react-apollo

kavink commented 6 years ago

@IvanGoncharov thanks that works for queries but does not work when mutation is called , and mutation has refetchQueries

kavink commented 6 years ago

https://www.apollographql.com/docs/react/basics/mutations.html#graphql-mutation-options-refetchQueries

IvanGoncharov commented 6 years ago

@kavink Thank for the link. We personally don't use Apollo so it would be great if some Apollo expert helps us to answer this question. PR that adds relevant info to README is very welcomed.