You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I use this great lib for a chat widget, with the constraint to have the possibility of a dynamic reset. The issue is that when I make the reset I need to re-set the socket instance used by VueSocketIOExt with new parameters.
What I do today is:
// First set-upVue.use(VueSocketIOExt,io(SOCKET_URL,OPTIONS),)// Before the resetVue.prototype.$socket.client.close();Vue.prototype.$socket.client.destroy();// Then the reset happening:Vue.use(VueSocketIOExt,io(SOCKET_URL,MY_NEW_OPTIONS),)
The result is that the emission try to use the old instance of SocketIO client and not the new one I just set. Would you consider in your roadmap to split the installation and the set of the SocketIO client ? today I need to do some hack like:
@probil: This is a bit over my head, but a comment to this post suggests that this Vuex method may demonstrate a way to un-use / uninstall a Vue plugin. Will try to research more later.
I need this. My current project requires me to implement server selection for the users. When connecting to the first server, users cannot just "logout" and connect to a different one. Any way around this ?
Hi,
I use this great lib for a chat widget, with the constraint to have the possibility of a dynamic reset. The issue is that when I make the reset I need to re-set the socket instance used by VueSocketIOExt with new parameters.
What I do today is:
It seems that do not work because of VueJS
use
logic that do not apply all operations if the module was already installed:https://github.com/vuejs/vue/blob/399b53661b167e678e1c740ce788ff6699096734/test/unit/features/global-api/use.spec.js#L20
The result is that the emission try to use the old instance of SocketIO client and not the new one I just set. Would you consider in your roadmap to split the installation and the set of the SocketIO client ? today I need to do some hack like:
but depending of VueJS core keys and that's not good...
The text was updated successfully, but these errors were encountered: