My FeedDiscussionsHeadless CMS
New
Sign in
Log inSign up
Learn more about Hashnode Headless CMSHashnode Headless CMS
Collaborate seamlessly with Hashnode Headless CMS for Enterprise.
Upgrade ✨Learn more

Can anyone tell me what is subscription in GraphQL and why we need that?

Aniketh Saha's photo
Aniketh Saha
·Jun 2, 2018

I am working with graphql and using apollo for implementing it . Everything was fine till apollo-client . but then I came in a question like if I want a user Authentication then I cant have a whole valitation and authenticating method inside a single resolve method. I came to apollo-server and then it got worse. My question

  • What is subscription in graphql?

  • Why we need this?

  • WIll subscription solve my problem of the login system ?

  • if not! how will I solve it?