[Vuejs]-Why is this JS/jQuery acting on multiple inputs?

0👍

Solved

I figured it out, but not sure as to why this is happening. It has to do with the vue directive. “v-if” causes the error, but “v-show” does not and allows it to work perfectly. If anyone can answer as to why this is happening, I will accept the answer.

0👍

I just copied you code, exactly like you send it and there is no event listener is attached to the ‘twofactor’ input as you can see here.enter image description here Maybe the problem is in other scripts or something you didn’t put in the question, because using only the code you send, everything is working as expected.

Leave a comment