-
Hello, I see the documentation and try to do this for applying
But I am getting-
Then I search and get idea for doing this-
And-
but here in this line
What is the proper way for applying |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
You'll have to check the graphql-ws docs. Basically, you can add the polyfill if you need the transport server-side If you're only using it for subscriptions however, I doubt that you'll need it. As the types say, you can't just null out parts of the API you're using and will instead have to exclude the entire |
Beta Was this translation helpful? Give feedback.
tl;dr, don't do this:
That'll make
unsubscribe
undefined whenwsClient
isundefined
, and TypeScript will (rightfully) yell at you, as you've seen.Instead, exclude the entire exchange if you don't need it, e.g.: