jquery的each和JS的for比较

86281940 2017-02-24

推荐减法的for

jsperf地址:https://jsperf.com/zlq463947

<script src="//ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.3/underscore-min.js"></script>

<script>
  var pi = Math.PI
  var a = new Array(1000000),
      e;
</script>

 
jquery的each和JS的for比较
 

相关推荐

Web全栈笔记 / 0评论 2020-06-15