vue-websocket
vue-websocket copied to clipboard
How to set option before connect but not in Vue.use ?
Look like #7 But we need set option before connect but not in Vue.use
main.js
Vue.use(VueWebsocket, null, { autoConnect: false });
App.vue
created() {
// Like this? get the bar before connect
this.$socket.option = {
query: 'foo='+bar,
'transports': ['websocket'],
}
this.$socket.open();
}
Thanks