📜  onclick 聚焦 jquery - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:13.800000             🧑  作者: Mango

代码示例1
var focus = 0,
  blur = 0;
$( "p" )
  .focusout(function() {
    focus++;
    $( "#focus-count" ).text( "focusout fired: " + focus + "x" );
  })
  .blur(function() {
    blur++;
    $( "#blur-count" ).text( "blur fired: " + blur + "x" );
  });