0

I am working with aws appsync for Grapql backend. But enable to use the Subscription feature on the client side using Apollo-angular though I am able to achieve mutations & query but not Subscription.

Code - https://stackblitz.com/edit/myapollo

Anzar Alim
  • 47
  • 8

1 Answers1

0

I checked out the stackblitz. I was (thought) is was stuck on the same issue. But it appeared, there was no issue. There is no need to setup a second client with a 'different' url. Subscriptions are offered out of the box with AppSync. The client 'knows' how to handle ws:

The AWS AppSync client SDK automatically handles subscription connection management.

Reference: https://docs.aws.amazon.com/appsync/latest/devguide/aws-appsync-real-time-data.html

Bob Meijwaard
  • 388
  • 9
  • 20
  • How about offline mode that is available with apollo client? Also it is weird that their Appsync SDK works only with react but not Angular. I'm trying to set up an offline setup for my Appsync Graphql with Angular. Can't find a solution. – Ragav Y Apr 03 '21 at 16:01