Skip to content

Commit bac634e

Browse files
author
Guillaume Chau
committed
Subscriptions docs fixes
1 parent 60786ba commit bac634e

File tree

1 file changed

+5
-13
lines changed

1 file changed

+5
-13
lines changed

README.md

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -684,6 +684,10 @@ export const resolvers = {
684684

685685
To make enable the websocket-based subscription, a bit of additional setup is required:
686686

687+
```
688+
npm install --save subscriptions-transport-ws
689+
```
690+
687691
```javascript
688692
import Vue from 'vue'
689693
import { ApolloClient, createNetworkInterface } from 'apollo-client'
@@ -715,19 +719,7 @@ const apolloClient = new ApolloClient({
715719
})
716720

717721
// Install the plugin like before
718-
Vue.use(VueApollo, {
719-
apolloClient,
720-
})
721-
722-
// Your app is now subscription-ready!
723-
724-
import App from './App.vue'
725-
726-
new Vue({
727-
el: '#app',
728-
render: h => h(App)
729-
})
730-
722+
Vue.use(VueApollo)
731723
```
732724

733725
### subscribeToMore

0 commit comments

Comments
 (0)