摘要: 2.18 groupBy 2.18.1 语法 _.groupBy(list, iteratee, [context]) 2.18.2 说明 把list分为多个集合,iterator为分组的依据,返回值为Object list可以是数组、对象、字符串或arguments等 iteratee为分组的依据 阅读全文
posted @ 2016-02-01 20:20 本相 阅读(485) 评论(0) 推荐(0) 编辑
摘要: 2.17 sortBy 2.17.1 语法 _.sortBy(list, iteratee, [context]) 2.17.2 说明 返回一个排序后的list拷贝副本。 list为集合,如数组、对象、字符串、arguments等 iteratee为排序的依据,可以为function,元素的属性、元 阅读全文
posted @ 2016-02-01 20:18 本相 阅读(2940) 评论(4) 推荐(0) 编辑
摘要: 2.16 min 2.16.1 语法: _.min(list, [iteratee], [context]) 2.16.2 说明: 返回list中的最小值。 list为集合,数组、对象、字符串或arguments iteratee作为返回最小值的依据 iteratee的参数(value, key, 阅读全文
posted @ 2016-02-01 10:25 本相 阅读(223) 评论(0) 推荐(0) 编辑
摘要: 2.15 max 2.15.1 语法: _.max(list, [iteratee], [context]) 2.15.2 说明: 返回list中的最小值。 list为集合,数组、对象、字符串或arguments iteratee作为返回最大值的依据 iteratee的参数(value, key, 阅读全文
posted @ 2016-02-01 10:24 本相 阅读(254) 评论(0) 推荐(0) 编辑