JSFiddle - React, Tailwind, and code Playground
HTML
<input name="f1" value="default">
<input name="f2" value="text" type="text">
JavaScript
$("input[type='text']").bind("keyup", function(e) {
var msg = "BIND(input/type) which=" + e.which
+ " type=" + $(this).attr("type");
console.log(msg);
});
$("input").bind("keyup", function(e) {
if ($(this).attr("type") == "text") {
var msg = "BIND(input) which=" + e.which
+ " type=" + $(this).attr("type");
console.log(msg);
}
});