I have a query like this.
const { loading, error, data } = useQuery(ME,{
onCompleted: data => {
console.log(data)
}
})
After executing this query, I can not execute this query again. How I can execute same query twice?
Turns out default fetchPolicy is "cache-first". I need to turn off like this.
const { loading, error, data } = useQuery(ME,{
onCompleted: data => {
console.log(data)
},
fetchPolicy: 'no-cache'
})