Does anyone know how to properly set the fetchPoli...
# orm-help
s
Does anyone know how to properly set the fetchPolicy on the newer Apollo Query Component? The docs don’t give an example… ie:
Copy code
<Query query={MY_QUERY} fetchPolicy={'network-only'}>
or
Copy code
<Query query={MY_QUERY} fetchPolicy="network-only">
n
that's rather a React/JSX question 🙂 both
fetchPolicy={'network-only'}
and
fetchPolicy="network-only"
should work. if you want to assign something else than a string to a React prop, you need to use
{}
s
Excellent, thanks Nilan