mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-06 09:47:48 +00:00
Remove compiling from _.reject and consolidate iterator option objects.
Former-commit-id: 10eb78c0c4cdfc35317b9ad263768df60f70db40
This commit is contained in:
6
build.js
6
build.js
@@ -135,7 +135,7 @@
|
||||
'range': [],
|
||||
'reduce': ['forEach'],
|
||||
'reduceRight': ['forEach', 'keys'],
|
||||
'reject': ['identity'],
|
||||
'reject': ['filter'],
|
||||
'rest': [],
|
||||
'result': ['isFunction'],
|
||||
'shuffle': ['forEach'],
|
||||
@@ -1191,8 +1191,8 @@
|
||||
// simplify DOM node check from `_.isEqual`
|
||||
source = source.replace(/(if *\(className *!= *objectClass).+?noNodeClass[\s\S]+?{/, '$1) {');
|
||||
|
||||
// remove "exit early" feature from `_.each`
|
||||
source = source.replace(/( +)var baseIteratorOptions *=[\s\S]+?\n\1.+?;/, function(match) {
|
||||
// remove "exit early" feature from `_.forEach`, `_.forIn`, and `_.forOwn`
|
||||
source = source.replace(/( +)var forEachIteratorOptions *=[\s\S]+?\n\1.+?;/, function(match) {
|
||||
return match.replace(/if *\(callback[^']+/, 'callback(value, index, collection)');
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user