mirror of
https://github.com/tenrok/vue-native-websocket.git
synced 2026-06-19 01:20:35 +03:00
dev: fix when manually connect and reconnect
This commit is contained in:
@@ -14,6 +14,7 @@ export default {
|
|||||||
|
|
||||||
if (opts.connectManually) {
|
if (opts.connectManually) {
|
||||||
Vue.prototype.$connect = (connectionUrl = connection, connectionOpts = opts) => {
|
Vue.prototype.$connect = (connectionUrl = connection, connectionOpts = opts) => {
|
||||||
|
connectionOpts.$setInstance = opts.$setInstance
|
||||||
observer = new Observer(connectionUrl, connectionOpts)
|
observer = new Observer(connectionUrl, connectionOpts)
|
||||||
Vue.prototype.$socket = observer.WebSocket
|
Vue.prototype.$socket = observer.WebSocket
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user