level 10
ssamtea
楼主
见过一栏js代码,首行是这么写的
!function(a){
jQuery.fn[a]=function(e){
return e?this.bind("resize",(t=e,function(){
var e=this,a=arguments;
i?clearTimeout(i):n&&t.apply(e,a),i=setTimeout(function(){
n||t.apply(e,a),i=null}
,o||100)}
)):this.trigger(a);
var t,o,n,i}
}((jQuery,"smartresize"));
这里面jQuery.fn[a]是表示什么意思?中括号表示什么?还有最后一行小括号里面还有(jQuery,"smartresize"),这句是什么写法?
2020年10月25日 15点10分
1
!function(a){
jQuery.fn[a]=function(e){
return e?this.bind("resize",(t=e,function(){
var e=this,a=arguments;
i?clearTimeout(i):n&&t.apply(e,a),i=setTimeout(function(){
n||t.apply(e,a),i=null}
,o||100)}
)):this.trigger(a);
var t,o,n,i}
}((jQuery,"smartresize"));
这里面jQuery.fn[a]是表示什么意思?中括号表示什么?还有最后一行小括号里面还有(jQuery,"smartresize"),这句是什么写法?