thomaswright / graphcool-auth0-apollo-auth-example

graphcool auth with react router v4
1 stars 0 forks source link

Why sign in to Graphcool? #1

Open denkristoffer opened 7 years ago

denkristoffer commented 7 years ago

Hi Thomas, sorry for asking this here but I couldn't find anywhere else to reach you. First of all, this repo is super helpful, so thank you for creating it 🙂 I'm just wondering why you sign in to both Auth0 and Graphcool when logging in a user? As far as I can see from Graphcool's own documentation, signing in to Auth0 should be enough, and when I remove the signinUser mutation from your code everything still seems to work fine. Is there some advantage I'm overlooking?

thomaswright commented 7 years ago

Hi @denkristoffer , I built this when Graphcool used a different auth token from the one received from Auth0. You are correct, you no longer need to sign in to two different places, the Auth0 token should be enough. I'll try to grab a second to change the code; if you want, send a PR. Let me know if you have any other questions or suggestions for improvements! 🙂

denkristoffer commented 7 years ago

Cool, thanks for the response! I might look into a PR when I've streamlined my own setup then 🙂