From e70b69237345e8aba1b86ab8abb5414b41fbfc00 Mon Sep 17 00:00:00 2001 From: Channely Date: Mon, 16 Oct 2017 03:18:40 -0500 Subject: [PATCH] you can replace default path /socket.io with yours config like: Vue.use(VueSocketio, {url: 'http://localhost:3000', path: '/your_path'}); and you can set namespace the sametime: Vue.use(VueSocketio, {url: 'http://localhost:3000/namespace', path: '/your_path'}); all these above will create the connect like: ws://localhost:3000/your_path/... --- src/Observer.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Observer.js b/src/Observer.js index e1afdcc..846ab91 100755 --- a/src/Observer.js +++ b/src/Observer.js @@ -7,6 +7,8 @@ export default class{ if(typeof connection == 'string'){ this.Socket = Socket(connection); + }else if(connection.url){ + this.Socket = Socket(connection.url, {path: connection.path ? connection.path : '/socket.io'}); }else{ this.Socket = connection }