MetinSeylan / Vue-Socket.io

😻 Socket.io implementation for Vuejs and Vuex
https://metin.sh
MIT License
3.95k stars 496 forks source link

Cannot call a class as a function [PROBLEM FOUND] #286

Open Gaeta opened 3 years ago

Gaeta commented 3 years ago

174 Uncaught TypeError: Cannot call a class as a function

Issue is still happening. v3.0.10

vue-socketio.js?5132:10 Uncaught TypeError: Cannot call a class as a function
    at eval (vue-socketio.js?5132:10)
    at t (vue-socketio.js?5132:10)
    at eval (main.js?56d7:27)
    at Module../src/main.js (app.js:1251)
    at __webpack_require__ (app.js:854)
    at fn (app.js:151)
    at Object.1 (app.js:1336)
    at __webpack_require__ (app.js:854)
    at checkDeferredModules (app.js:46)
    at app.js:994
Gaeta commented 3 years ago

found issue

Vue.use(VueSocketIO)

change it to

Vue.use(new VueSocketIO)

Please update the docs