Our great sponsors
-
graphql-ws
Coherent, zero-dependency, lazy, simple, GraphQL over WebSocket Protocol compliant server and client.
-
graphql-sse
Zero-dependency, HTTP/1 safe, simple, GraphQL over Server-Sent Events Protocol server and client.
-
SurveyJS
Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
-
graphql-zeus
GraphQL client and GraphQL code generator with GraphQL autocomplete library generation ⚡⚡⚡ for browser,nodejs and react native ( apollo compatible )
The GraphQL over WebSocket solution definitely requires an additional library on the client for the complexity of the protocol (namely graphql-ws). The readme of that project describes how you can connect to a GraphQL over WebSocket compliant server.
The GraphQL over SSE in its simplest form IMHO does not require an additional client library. Setting up a subscription in the browser is as simple as doing the following:
https://github.com/graphql-editor/graphql-zeus generates subscription code and in generated code you'll find simple apiSubscription function you can use/copy