vuejs-toggle-switch icon indicating copy to clipboard operation
vuejs-toggle-switch copied to clipboard

Cannot read property of undefined

Open camproto opened this issue 3 years ago • 7 comments

Expected Behavior

Imports ToggleSwitch vue component

Actual Behavior

run dev works successfully, but open the vue app in browser crashes with

Uncaught TypeError: Cannot read properties of undefined (reading 'call') at t (ToggleSwitch.common.js:4161:1) at ToggleSwitch.common.js:4265:1 at ToggleSwitch.common.js:4658:1 at Object. (ToggleSwitch.common.js:4662:1) at t (bootstrap c82ee93e959505698e6a:50:1) at Object.0 (main.js:23:1) at t (bootstrap c82ee93e959505698e6a:50:1) at window.webpackJsonp (bootstrap c82ee93e959505698e6a:21:1) at app.c9c6732361ce2d5c8e26.js:1:1 t @ ToggleSwitch.common.js:4161 (anonymous) @ ToggleSwitch.common.js:4265 (anonymous) @ ToggleSwitch.common.js:4658 (anonymous) @ ToggleSwitch.common.js:4662 t @ bootstrap c82ee93e959505698e6a:50 0 @ main.js:23 t @ bootstrap c82ee93e959505698e6a:50 window.webpackJsonp @ bootstrap c82ee93e959505698e6a:21 (anonymous) @ app.c9c6732361ce2d5c8e26.js:1

Steps to Reproduce the Problem

  1. npm run dev 2.open browser on dev server :8082 3.white page - find above error in browser console

Specifications

  1. "vuejs-toggle-switch": "^1.3.1" 2."webpack": "^1.13.2", 3."vue": "2.5.22",

This issue starts around the time you published new version 1.3.4.

We tried with your new version 1.3.4 and got this issue in console Uncaught SyntaxError: Cannot use import statement outside a module at Object. (app.js:864:2) at webpack_require (app.js:556:30) at fn (app.js:87:20) at eval (eval at (app.js:3060:2), :11:19) at Object. (app.js:3060:2) at webpack_require (app.js:556:30) at fn (app.js:87:20) at eval (eval at (app.js:6684:2), :8:19) at Object. (app.js:6684:2) at webpack_require (app.js:556:30)

What might be changed on the old version 1.3.1?

camproto avatar Jun 07 '22 12:06 camproto

I am also facing the same issue but with 1.3.1 version as well.

kirandeep123 avatar Jun 08 '22 05:06 kirandeep123

Can you upgrade to the latest version (2.0.0)? and retest?

larsmars avatar Jun 08 '22 06:06 larsmars

I have the same issue with 2.0.0 version.

mtribuzio avatar Aug 10 '22 21:08 mtribuzio

Facing the same issue. I'm on the latest version(2.0.0). Has anyone found a solution?

harunthuo avatar Dec 14 '22 16:12 harunthuo

@larsmars Could you kindly provide some feedback on this bug?

harunthuo avatar Feb 18 '23 10:02 harunthuo

Rolled back to version 1.3.1 and I no longer get the bug.

harunthuo avatar Feb 21 '23 07:02 harunthuo

This should now be updated on latest release (for Vue 3). Please report back if there is still a problem 😃

larsmars avatar May 17 '23 17:05 larsmars