首页 >社区问答列表 >为什么是even

为什么是even

$("content").slideDown('slow',function(even){

}

为什么是有even

  • Pxm
  • Pxm    2022-02-22 15:50:352楼

    这个even源自于 这个匿名函数的上一层函数,上一层函数调用时传递了一个实参(even)  所以这个匿名函数的行参就可以使用了 .

    +0添加回复

  • 回复
  • autoload
  • autoload    2022-02-14 10:14:041楼

    这个只是一个形式参数

    +0添加回复

  • 回复

    如果没有可以运行么

    P粉176222609  作者 · 2022-02-14 10:14:54
    回复

    $a = function() { return 111 }; $a(even) 实参数量可以 大于 形参 所以写不写都行.

    Pxm · 2022-02-22 15:58:54
    回复