1.0.20 • Published 6 years ago

apollo-link-ws v1.0.20

Weekly downloads
365,993
License
MIT
Repository
github
Last release
6 years ago

title: apollo-link-ws

description: Send GraphQL operations over a WebSocket. Works with GraphQL Subscriptions.

This link is particularly useful to use GraphQL Subscriptions, but it will also allow you to send GraphQL queries and mutations over WebSockets as well.

import { WebSocketLink } from "apollo-link-ws";
import { SubscriptionClient } from "subscriptions-transport-ws";

const GRAPHQL_ENDPOINT = "ws://localhost:3000/graphql";

const client = new SubscriptionClient(GRAPHQL_ENDPOINT, {
  reconnect: true
});

const link = new WebSocketLink(client);

Options

WS Link takes either a subscription client or an object with three options on it to customize the behavior of the link. Takes the following possible keys in the configuration object:

  • uri: a string endpoint to connect to
  • options: a set of options to pass to a new Subscription Client
  • webSocketImpl: a custom WebSocket implementation

By default, this link uses the subscriptions-transport-ws library for the transport.

@kikstart-graphql/client@kikstart-graphql/corereact-native-erxes@igloo_cloud/shared-ui@coderich/autographql@getholo/cli@puzl/puzl-cloud_authorization-modulebitguild-blockchain-sdkirisvr-cloud-util@moonwalker/lifesupportgraphql-playground-react-auth@etherspot/platform-clientdevelapp-regional-frontend@coderich/autograph-server@chargetrip/javascript-sdkecp-frontend@platyplus/hasura-apollo-clientxr3-clientbitcasino-v3@alpine-code/node-red-contrib-thelabreact-nhostmonetrum-node-client@getcaya/prisma-bindingudiachimp.clickgraphql-api-gatewaynet.vixonic.player@collaveinc/quasar-app-extension-workbench-apollo@everything-registry/sub-chunk-1153tdlc-coresyn-mappingtemporary-midas-packagewith-apollowalkuerewalkuere-corewalkuere-rnvue-neo4jvue-cli-plugin-apollovue-cli-plugin-apollo-graphql-wsvue-cli-plugin-apollo-without-regenerator-runtimesumimar-apisvelte-apollo-clientthemis-graphqltibber-pulse-connectorvixonicvue-doc-calendarviam-projectv-scan@donatas123/core@donatas123/front@blueeast/bluerain-plugin-apollo-link-ws@prg/gatsby-theme-bedrock@prisma-cms/frontk2-education-fekms-web-appinfiscenariohybrid-clientgt-gatsby-wagtailhasura-data-enginehasura-sub-fetchhasurafiregraphql-client-bindingsgraphql-engine-consolelevellearning-core-sdklimegreenjsluminolluminol-webpacklumen-cmsmaronato-vue-cli-plugin-apollomchs-documentslpack-ts-react-apollomake-apollo-clientkikstart-graphql-clientreactiveweb-login-ui@wildcards/reason-apollo@wcfactory/ui@webscopeio/graphql-playground-react@udia/udia@udia/udia-client@vksci123/console-oss@vksci123/hasura-modules@vukhaihoan/prime-sdk@zetaorg/client@zeplo/prisma-binding@zmok-red/zmok-redagnostic-rpc-graphqlaisi-cli-plugin-apolloabridgedapi-gateway-serviceapollo-bindingappelisgraphclientapollo-offline-clientapollo-client-ssrapollo-demoapollo-split-client0xql@grafee/client@gqlkit/client@chromapdx/apollo@clutch-marketplace/apollo@graphcms/prisma-binding
1.0.20

6 years ago

2.0.0-beta.0

6 years ago

1.0.19

6 years ago

1.0.18

6 years ago

1.0.17

7 years ago

1.0.16

7 years ago

1.0.15

7 years ago

1.0.14

7 years ago

1.0.13

7 years ago

1.0.12

7 years ago

1.0.11

7 years ago

1.0.10

7 years ago

1.0.9

7 years ago

1.0.8

8 years ago

1.0.7

8 years ago

1.0.6

8 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago

0.6.0

8 years ago

0.5.0

8 years ago

0.4.1-beta.6

8 years ago

0.4.1-beta.5

8 years ago

0.4.1-beta.3

8 years ago

0.4.1-beta.4

8 years ago

0.4.1-beta.1

8 years ago

0.4.1-beta.0

8 years ago

0.3.4

8 years ago

0.3.2

8 years ago

0.3.0

8 years ago

0.2.1

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago

0.2.0

8 years ago

0.0.0

8 years ago