摘要: html部分: 记得引入jq哦! js部分: 插件: 插件使用: 阅读全文
posted @ 2016-04-03 16:28 康武大帝 阅读(255) 评论(0) 推荐(0)
摘要: 简单的数组求最大值 Math.max(1,2,3,4); // =>4 var arr = [1,2,3,4]; Math.max.apply(null,arr); // =>4 arr.reduce(function(x,y){ return (x<y) ? x : y; }) reduce为es 阅读全文
posted @ 2016-03-05 15:43 康武大帝 阅读(176) 评论(0) 推荐(0)