Below is the App.js file I have used for my react-native expo project with Apollo. The last line throws error saying (0, _reactApollo2.default) is not a function. (In '(0, _reactApollo2.default)'(MY_QUERY), '(0, _reactApollo2.default)' is undefined.
The AppNavigation file used in the above file is here
The apollo connection is setup and working properly. Is there anything wrong in the above file? Please guide.
@KenilDomadia You should change your import statement to
import {graphql} from 'react-apollo'
because graphql is not a default export of react-apollo package
That helped. It was a real silly mistake. Thanks.
This issue has been automatically labled because it has not had recent activity. If you have not received a response from anyone, please mention the repository maintainer (most likely @jbaxleyiii). It will be closed if no further activity occurs. Thank you for your contributions to React Apollo!
Most helpful comment
@KenilDomadia You should change your import statement to
because
graphqlis not a default export ofreact-apollopackage