2
0
mirror of https://github.com/tenrok/vue-native-websocket.git synced 2026-05-25 05:44:05 +03:00

dev: fix when manually connect and reconnect

This commit is contained in:
Lyndon
2019-02-22 13:29:36 +08:00
parent c44d62b7a3
commit 9a4762f8a6
+1
View File
@@ -14,6 +14,7 @@ export default {
if (opts.connectManually) {
Vue.prototype.$connect = (connectionUrl = connection, connectionOpts = opts) => {
connectionOpts.$setInstance = opts.$setInstance
observer = new Observer(connectionUrl, connectionOpts)
Vue.prototype.$socket = observer.WebSocket
}