adamsoffer / next-apollo

React higher-order component for integrating Apollo Client with Next.js
MIT License
482 stars 64 forks source link

Integrate with new @apollo/react-hooks #37

Closed adamsoffer closed 5 years ago

adamsoffer commented 5 years ago

If anyone is interested, you can now use apollo hooks with this library :) npm install --save next-apollo@beta

DavoCg commented 5 years ago

Hi @adamsoffer I give a try to next-apollo@beta and I have this error Cannot read property 'apollo' of undefined and I think it comes from here : https://github.com/adamsoffer/next-apollo/blob/73a9ca0729b20ee738db4465436e75af29242291/src/withData.js#L72

I'll continue trying to make it works.

I could be interesting to have a working example with next-apollo@beta and @apollo/react-hooks

adamsoffer commented 5 years ago

Hey @DavoCg - I actually just updated the next-apollo-example repo to use next-apollo@beta if you wanna have a look there :)

https://github.com/adamsoffer/next-apollo-example