I have an event that I want to fire on keyup of an input. the code works perfectly fine in JsFiddle, but when I run in .NET MVC Partial view, nothing happens.
so for example this is the JsFiddle
exactly the same code (except the part with click me, to add text field) does not work in my view. What is even stranger that this code:
$(document).on("keyup","#propName", function () {
alert($("#propName").val());
});
works without any problems and the event is fired, but as soon as I add an IF statement the code is not executing at all (also no error messages in the console)
What am I doing wrong?
question from:
https://stackoverflow.com/questions/65847412/javascript-function-works-in-jsfiddle-but-not-in-net-partial-view 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…