Open aripjanovsh opened 4 years ago
Added multiple connections actionPrefix and mutationPrefix functions
import Vue from 'vue' import store from './store' import App from './App.vue' import VueSocketIO from 'vue-socket.io' const app = SocketIO('http://localhost:1090', { useConnectionNamespace: true, }); const chat = SocketIO('http://localhost:1090/chat', { useConnectionNamespace: true, autoConnect: false, }); Vue.use(new VueSocketIO({ debug: true, connection: { app, chat }, vuex: { store, actionPrefix: eventName => { return (`SOCKET_` + eventName).toUpperCase(); }, mutationPrefix: eventName => { return (`SOCKET_` + eventName).toUpperCase(); }, }, options: { path: "/my-app/" } //Optional options }))
is this ok? i need this update! please!
work without vuex?
Added multiple connections actionPrefix and mutationPrefix functions