mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-01-29 06:27:49 +00:00
Bump to version 1.0.0-rc.1.
Former-commit-id: 8867f4ddfab62435d0c2c685d67e68555d146545
This commit is contained in:
64
README.md
64
README.md
@@ -1,17 +1,25 @@
|
||||
# Lo-Dash <sup>v0.10.0</sup>
|
||||
# Lo-Dash <sup>v1.0.0-rc.1</sup>
|
||||
[](http://travis-ci.org/bestiejs/lodash)
|
||||
|
||||
A drop-in replacement<sup>[*](https://github.com/bestiejs/lodash/wiki/Drop-in-Disclaimer)</sup> for Underscore.js, from the devs behind [jsPerf.com](http://jsperf.com), delivering [performance](http://lodash.com/benchmarks), [bug fixes](https://github.com/bestiejs/lodash#resolved-underscorejs-issues), and [additional features](http://lodash.com/#features).
|
||||
|
||||
Lo-Dash’s performance is gained by avoiding slower native methods, instead opting for simplified non-ES5 compliant methods optimized for common usage, and by leveraging function compilation to reduce the number of overall function calls.
|
||||
A utility library, usable as a drop-in replacement for Underscore.js, delivering [performance](http://lodash.com/benchmarks), [bug fixes](https://github.com/bestiejs/lodash#resolved-underscorejs-issues), and [additional features](http://lodash.com/#features).
|
||||
|
||||
## Download
|
||||
|
||||
* [Development build](https://raw.github.com/bestiejs/lodash/v0.10.0/lodash.js)
|
||||
* [Production build](https://raw.github.com/bestiejs/lodash/v0.10.0/lodash.min.js)
|
||||
* [Underscore build](https://raw.github.com/bestiejs/lodash/v0.10.0/lodash.underscore.min.js) tailored for projects already using Underscore
|
||||
* CDN copies of ≤ v0.10.0’s [Production](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/0.10.0/lodash.min.js), [Underscore](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/0.10.0/lodash.underscore.min.js), and [Development](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/0.10.0/lodash.js) builds are available on [cdnjs](http://cdnjs.com/) thanks to [CloudFlare](http://www.cloudflare.com/)
|
||||
* For optimal file size, [create a custom build](https://github.com/bestiejs/lodash#custom-builds) with only the features you need
|
||||
* Lo-Dash builds:<br>
|
||||
[Development](https://raw.github.com/bestiejs/lodash/v1.0.0-rc.1/lodash.js) and
|
||||
[Production](https://raw.github.com/bestiejs/lodash/v1.0.0-rc.1/lodash.min.js)
|
||||
|
||||
* Underscore builds:<br>
|
||||
[Development](https://raw.github.com/bestiejs/lodash/v1.0.0-rc.1/lodash.underscore.js) and
|
||||
[Production](https://raw.github.com/bestiejs/lodash/v1.0.0-rc.1/lodash.underscore.min.js)
|
||||
|
||||
* CDN copies of ≤ v1.0.0-rc.1’s builds on [cdnjs](http://cdnjs.com/) thanks to [CloudFlare](http://www.cloudflare.com/):<br>
|
||||
[Lo-Dash development](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/1.0.0-rc.1/lodash.js),
|
||||
[Lo-Dash production](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/1.0.0-rc.1/lodash.min.js),
|
||||
[Underscore development](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/1.0.0-rc.1/lodash.underscore.js), and
|
||||
[Underscore production](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/1.0.0-rc.1/lodash.underscore.min.js)
|
||||
|
||||
* For optimal file size, [create a custom build](https://github.com/bestiejs/lodash#custom-builds) with only the features you need
|
||||
|
||||
## Dive in
|
||||
|
||||
@@ -216,34 +224,34 @@ require({
|
||||
|
||||
## Resolved Underscore.js issues
|
||||
|
||||
* Allow iteration of objects with a `length` property [[#799](https://github.com/documentcloud/underscore/pull/799), [test](https://github.com/bestiejs/lodash/blob/v0.10.0/test/test.js#L590-L596)]
|
||||
* Fix cross-browser object iteration bugs [[#60](https://github.com/documentcloud/underscore/issues/60), [#376](https://github.com/documentcloud/underscore/issues/376), [test](https://github.com/bestiejs/lodash/blob/v0.10.0/test/test.js#L603-L627)]
|
||||
* Methods should work on pages with incorrectly shimmed native methods [[#7](https://github.com/documentcloud/underscore/issues/7), [#742](https://github.com/documentcloud/underscore/issues/742), [test](https://github.com/bestiejs/lodash/blob/v0.10.0/test/test.js#L140-L146)]
|
||||
* `_.isEmpty` should support jQuery/MooTools DOM query collections [[#690](https://github.com/documentcloud/underscore/pull/690), [test](https://github.com/bestiejs/lodash/blob/v0.10.0/test/test.js#L792-L797)]
|
||||
* `_.isObject` should avoid V8 bug [#2291](http://code.google.com/p/v8/issues/detail?id=2291) [[#605](https://github.com/documentcloud/underscore/issues/605), [test](https://github.com/bestiejs/lodash/blob/v0.10.0/test/test.js#L873-L885)]
|
||||
* `_.keys` should work with `arguments` objects cross-browser [[#396](https://github.com/documentcloud/underscore/issues/396), [test](https://github.com/bestiejs/lodash/blob/v0.10.0/test/test.js#L966-L968)]
|
||||
* `_.range` should coerce arguments to numbers [[#634](https://github.com/documentcloud/underscore/issues/634), [#683](https://github.com/documentcloud/underscore/issues/683), [test](https://github.com/bestiejs/lodash/blob/v0.10.0/test/test.js#L1367-L1370)]
|
||||
* Allow iteration of objects with a `length` property [[#799](https://github.com/documentcloud/underscore/pull/799), [test](https://github.com/bestiejs/lodash/blob/v1.0.0-rc.1/test/test.js#L606-L612)]
|
||||
* Fix cross-browser object iteration bugs [[#60](https://github.com/documentcloud/underscore/issues/60), [#376](https://github.com/documentcloud/underscore/issues/376), [test](https://github.com/bestiejs/lodash/blob/v1.0.0-rc.1/test/test.js#L619-L643)]
|
||||
* Methods should work on pages with incorrectly shimmed native methods [[#7](https://github.com/documentcloud/underscore/issues/7), [#742](https://github.com/documentcloud/underscore/issues/742), [test](https://github.com/bestiejs/lodash/blob/v1.0.0-rc.1/test/test.js#L140-L146)]
|
||||
* `_.isEmpty` should support jQuery/MooTools DOM query collections [[#690](https://github.com/documentcloud/underscore/pull/690), [test](https://github.com/bestiejs/lodash/blob/v1.0.0-rc.1/test/test.js#L808-L813)]
|
||||
* `_.isObject` should avoid V8 bug [#2291](http://code.google.com/p/v8/issues/detail?id=2291) [[#605](https://github.com/documentcloud/underscore/issues/605), [test](https://github.com/bestiejs/lodash/blob/v1.0.0-rc.1/test/test.js#L889-L901)]
|
||||
* `_.keys` should work with `arguments` objects cross-browser [[#396](https://github.com/documentcloud/underscore/issues/396), [test](https://github.com/bestiejs/lodash/blob/v1.0.0-rc.1/test/test.js#L982-L984)]
|
||||
* `_.range` should coerce arguments to numbers [[#634](https://github.com/documentcloud/underscore/issues/634), [#683](https://github.com/documentcloud/underscore/issues/683), [test](https://github.com/bestiejs/lodash/blob/v1.0.0-rc.1/test/test.js#L1383-L1386)]
|
||||
|
||||
## Release Notes
|
||||
|
||||
### <sup>v0.10.0</sup>
|
||||
### <sup>v1.0.0-rc.1</sup>
|
||||
|
||||
#### Compatibility Warnings ####
|
||||
|
||||
* Made `_.defaults` and `_.extend` iterate only own properties of `source` objects to align with [ES6 `Object.assign`](http://people.mozilla.org/~jorendorff/es6-draft.html#sec-15.2.3.15)
|
||||
* Renamed `_.lateBind` to `_.bindKey`
|
||||
* Made `_(…)` chain automatically without needing to call `_#chain`
|
||||
* Made `_.isEqual` equate `arguments` objects to similar Object objects
|
||||
* Made `_.clone` copy the enumerable properties of `arguments` objects and objects<br>
|
||||
created by constructors other than `Object` are cloned to plain Object objects
|
||||
|
||||
#### Changes ####
|
||||
|
||||
* Added the build commands used to custom build copyright/license headers
|
||||
* Added `_.assign`
|
||||
* Ensured the `underscore` build of `_.find` returns the first, not last, matched value
|
||||
* Ensured `_defaults`, `_.extends`, and `_.merge` work with `_.reduce`
|
||||
* Made Lo-Dash’s `npm` package installation work with more system configurations
|
||||
* Made `_.extend` an alias of `_.assign`
|
||||
* Optimized `_.contains`, `_.defaults`, `_.extend`, and `_.filter`
|
||||
* Restricted `_.where` to iterate only own properties of the `source` object
|
||||
* Updated `backbone` build Lo-Dash method dependencies
|
||||
* Ensure Lo-Dash runs in the JS engine embedded in various Adobe products
|
||||
* Ensured `bound` result of `_.bind(func, …)` is an instance of `bound` and `func`
|
||||
* Ensured `_.reduce` and `_.reduceRight` pass the correct number of `callback` arguments
|
||||
* Made deep `_.clone` more closely follow the structured clone algorithm and copy array properties assigned by `RegExp#exec`
|
||||
* Optimized compiled templates in Firefox
|
||||
* Optimized `_.forEach`, `_.forOwn`, `_.isNumber`, and `_.isString`
|
||||
* Simplified `iteratorTemplate`
|
||||
|
||||
The full changelog is available [here](https://github.com/bestiejs/lodash/wiki/Changelog).
|
||||
|
||||
|
||||
210
doc/README.md
210
doc/README.md
@@ -1,4 +1,4 @@
|
||||
# Lo-Dash <sup>v0.10.0</sup>
|
||||
# Lo-Dash <sup>v1.0.0-rc.1</sup>
|
||||
|
||||
<!-- div -->
|
||||
|
||||
@@ -186,7 +186,7 @@
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_compactarray"></a>`_.compact(array)`
|
||||
<a href="#_compactarray">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2663 "View in source") [Ⓣ][1]
|
||||
<a href="#_compactarray">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2633 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array with all falsey values of `array` removed. The values `false`, `null`, `0`, `""`, `undefined` and `NaN` are all falsey.
|
||||
|
||||
@@ -210,7 +210,7 @@ _.compact([0, 1, false, 2, '', 3]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_differencearray--array1-array2-"></a>`_.difference(array [, array1, array2, ...])`
|
||||
<a href="#_differencearray--array1-array2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2693 "View in source") [Ⓣ][1]
|
||||
<a href="#_differencearray--array1-array2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2663 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array of `array` elements not present in the other arrays using strict equality for comparisons, i.e. `===`.
|
||||
|
||||
@@ -235,7 +235,7 @@ _.difference([1, 2, 3, 4, 5], [5, 2, 10]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_firstarray--n"></a>`_.first(array [, n])`
|
||||
<a href="#_firstarray--n">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2728 "View in source") [Ⓣ][1]
|
||||
<a href="#_firstarray--n">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2698 "View in source") [Ⓣ][1]
|
||||
|
||||
Gets the first element of the `array`. Pass `n` to return the first `n` elements of the `array`.
|
||||
|
||||
@@ -263,7 +263,7 @@ _.first([5, 4, 3, 2, 1]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_flattenarray-shallow"></a>`_.flatten(array, shallow)`
|
||||
<a href="#_flattenarray-shallow">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2755 "View in source") [Ⓣ][1]
|
||||
<a href="#_flattenarray-shallow">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2725 "View in source") [Ⓣ][1]
|
||||
|
||||
Flattens a nested array *(the nesting can be to any depth)*. If `shallow` is truthy, `array` will only be flattened a single level.
|
||||
|
||||
@@ -291,7 +291,7 @@ _.flatten([1, [2], [3, [[4]]]], true);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_indexofarray-value--fromindex0"></a>`_.indexOf(array, value [, fromIndex=0])`
|
||||
<a href="#_indexofarray-value--fromindex0">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2797 "View in source") [Ⓣ][1]
|
||||
<a href="#_indexofarray-value--fromindex0">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2767 "View in source") [Ⓣ][1]
|
||||
|
||||
Gets the index at which the first occurrence of `value` is found using strict equality for comparisons, i.e. `===`. If the `array` is already sorted, passing `true` for `fromIndex` will run a faster binary search.
|
||||
|
||||
@@ -323,7 +323,7 @@ _.indexOf([1, 1, 2, 2, 3, 3], 2, true);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_initialarray--n1"></a>`_.initial(array [, n=1])`
|
||||
<a href="#_initialarray--n1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2832 "View in source") [Ⓣ][1]
|
||||
<a href="#_initialarray--n1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2802 "View in source") [Ⓣ][1]
|
||||
|
||||
Gets all but the last element of `array`. Pass `n` to exclude the last `n` elements from the result.
|
||||
|
||||
@@ -348,7 +348,7 @@ _.initial([3, 2, 1]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_intersectionarray1-array2-"></a>`_.intersection([array1, array2, ...])`
|
||||
<a href="#_intersectionarray1-array2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2856 "View in source") [Ⓣ][1]
|
||||
<a href="#_intersectionarray1-array2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2826 "View in source") [Ⓣ][1]
|
||||
|
||||
Computes the intersection of all the passed-in arrays using strict equality for comparisons, i.e. `===`.
|
||||
|
||||
@@ -372,7 +372,7 @@ _.intersection([1, 2, 3], [101, 2, 1, 10], [2, 1]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_lastarray--n"></a>`_.last(array [, n])`
|
||||
<a href="#_lastarray--n">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2894 "View in source") [Ⓣ][1]
|
||||
<a href="#_lastarray--n">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2864 "View in source") [Ⓣ][1]
|
||||
|
||||
Gets the last element of the `array`. Pass `n` to return the last `n` elements of the `array`.
|
||||
|
||||
@@ -397,7 +397,7 @@ _.last([3, 2, 1]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_lastindexofarray-value--fromindexarraylength-1"></a>`_.lastIndexOf(array, value [, fromIndex=array.length-1])`
|
||||
<a href="#_lastindexofarray-value--fromindexarraylength-1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2921 "View in source") [Ⓣ][1]
|
||||
<a href="#_lastindexofarray-value--fromindexarraylength-1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2891 "View in source") [Ⓣ][1]
|
||||
|
||||
Gets the index at which the last occurrence of `value` is found using strict equality for comparisons, i.e. `===`. If `fromIndex` is negative, it is used as the offset from the end of the collection.
|
||||
|
||||
@@ -426,7 +426,7 @@ _.lastIndexOf([1, 2, 3, 1, 2, 3], 2, 3);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_objectkeys--values"></a>`_.object(keys [, values=[]])`
|
||||
<a href="#_objectkeys--values">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2951 "View in source") [Ⓣ][1]
|
||||
<a href="#_objectkeys--values">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2921 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an object composed from arrays of `keys` and `values`. Pass either a single two dimensional array, i.e. `[[key1, value1], [key2, value2]]`, or two arrays, one of `keys` and one of corresponding `values`.
|
||||
|
||||
@@ -451,7 +451,7 @@ _.object(['moe', 'larry', 'curly'], [30, 40, 50]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_rangestart0-end--step1"></a>`_.range([start=0], end [, step=1])`
|
||||
<a href="#_rangestart0-end--step1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2996 "View in source") [Ⓣ][1]
|
||||
<a href="#_rangestart0-end--step1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2966 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array of numbers *(positive and/or negative)* progressing from `start` up to but not including `stop`. This method is a port of Python's `range()` function. See http://docs.python.org/library/functions.html#range.
|
||||
|
||||
@@ -489,7 +489,7 @@ _.range(0);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_restarray--n1"></a>`_.rest(array [, n=1])`
|
||||
<a href="#_restarray--n1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3035 "View in source") [Ⓣ][1]
|
||||
<a href="#_restarray--n1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3005 "View in source") [Ⓣ][1]
|
||||
|
||||
The opposite of `_.initial`, this method gets all but the first value of `array`. Pass `n` to exclude the first `n` values from the result.
|
||||
|
||||
@@ -517,7 +517,7 @@ _.rest([3, 2, 1]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_sortedindexarray-value--callbackidentityproperty-thisarg"></a>`_.sortedIndex(array, value [, callback=identity|property, thisArg])`
|
||||
<a href="#_sortedindexarray-value--callbackidentityproperty-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3079 "View in source") [Ⓣ][1]
|
||||
<a href="#_sortedindexarray-value--callbackidentityproperty-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3049 "View in source") [Ⓣ][1]
|
||||
|
||||
Uses a binary search to determine the smallest index at which the `value` should be inserted into `array` in order to maintain the sort order of the sorted `array`. If `callback` is passed, it will be executed for `value` and each element in `array` to compute their sort ranking. The `callback` is bound to `thisArg` and invoked with one argument; *(value)*. The `callback` argument may also be the name of a property to order by.
|
||||
|
||||
@@ -561,7 +561,7 @@ _.sortedIndex(['twenty', 'thirty', 'fifty'], 'fourty', function(word) {
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_unionarray1-array2-"></a>`_.union([array1, array2, ...])`
|
||||
<a href="#_unionarray1-array2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3110 "View in source") [Ⓣ][1]
|
||||
<a href="#_unionarray1-array2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3080 "View in source") [Ⓣ][1]
|
||||
|
||||
Computes the union of the passed-in arrays using strict equality for comparisons, i.e. `===`.
|
||||
|
||||
@@ -585,7 +585,7 @@ _.union([1, 2, 3], [101, 2, 1, 10], [2, 1]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_uniqarray--issortedfalse-callbackidentity-thisarg"></a>`_.uniq(array [, isSorted=false, callback=identity, thisArg])`
|
||||
<a href="#_uniqarray--issortedfalse-callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3144 "View in source") [Ⓣ][1]
|
||||
<a href="#_uniqarray--issortedfalse-callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3114 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a duplicate-value-free version of the `array` using strict equality for comparisons, i.e. `===`. If the `array` is already sorted, passing `true` for `isSorted` will run a faster algorithm. If `callback` is passed, each element of `array` is passed through a callback` before uniqueness is computed. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index, array)*.
|
||||
|
||||
@@ -624,7 +624,7 @@ _.uniq([1, 2, 1.5, 3, 2.5], function(num) { return this.floor(num); }, Math);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_withoutarray--value1-value2-"></a>`_.without(array [, value1, value2, ...])`
|
||||
<a href="#_withoutarray--value1-value2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3202 "View in source") [Ⓣ][1]
|
||||
<a href="#_withoutarray--value1-value2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3172 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array with all occurrences of the passed values removed using strict equality for comparisons, i.e. `===`.
|
||||
|
||||
@@ -649,7 +649,7 @@ _.without([1, 2, 1, 0, 3, 1, 4], 0, 1);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_ziparray1-array2-"></a>`_.zip([array1, array2, ...])`
|
||||
<a href="#_ziparray1-array2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3233 "View in source") [Ⓣ][1]
|
||||
<a href="#_ziparray1-array2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3203 "View in source") [Ⓣ][1]
|
||||
|
||||
Groups the elements of each array at their corresponding indexes. Useful for separate data sources that are coordinated through matching array indexes. For a matrix of nested arrays, `_.zip.apply(...)` can transpose the matrix in a similar fashion.
|
||||
|
||||
@@ -680,7 +680,7 @@ _.zip(['moe', 'larry', 'curly'], [30, 40, 50], [true, false, false]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_value"></a>`_(value)`
|
||||
<a href="#_value">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L259 "View in source") [Ⓣ][1]
|
||||
<a href="#_value">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L254 "View in source") [Ⓣ][1]
|
||||
|
||||
The `lodash` function.
|
||||
|
||||
@@ -698,7 +698,7 @@ The `lodash` function.
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_chainvalue"></a>`_.chain(value)`
|
||||
<a href="#_chainvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4103 "View in source") [Ⓣ][1]
|
||||
<a href="#_chainvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4073 "View in source") [Ⓣ][1]
|
||||
|
||||
Wraps the value in a `lodash` wrapper object.
|
||||
|
||||
@@ -732,7 +732,7 @@ var youngest = _.chain(stooges)
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_tapvalue-interceptor"></a>`_.tap(value, interceptor)`
|
||||
<a href="#_tapvalue-interceptor">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4128 "View in source") [Ⓣ][1]
|
||||
<a href="#_tapvalue-interceptor">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4098 "View in source") [Ⓣ][1]
|
||||
|
||||
Invokes `interceptor` with the `value` as the first argument, and then returns `value`. The purpose of this method is to "tap into" a method chain, in order to perform operations on intermediate results within the chain.
|
||||
|
||||
@@ -762,7 +762,7 @@ _.chain([1, 2, 3, 200])
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_prototypechain"></a>`_.prototype.chain()`
|
||||
<a href="#_prototypechain">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4150 "View in source") [Ⓣ][1]
|
||||
<a href="#_prototypechain">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4120 "View in source") [Ⓣ][1]
|
||||
|
||||
This function returns the wrapper object. Note: This function is defined to ensure the existing wrapper object is returned, instead of creating a new wrapper object like the `_.chain` method does.
|
||||
|
||||
@@ -783,7 +783,7 @@ _([1, 2, 3]).value();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_prototypetostring"></a>`_.prototype.toString()`
|
||||
<a href="#_prototypetostring">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4166 "View in source") [Ⓣ][1]
|
||||
<a href="#_prototypetostring">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4136 "View in source") [Ⓣ][1]
|
||||
|
||||
Produces the `toString` result of the wrapped value.
|
||||
|
||||
@@ -804,7 +804,7 @@ _([1, 2, 3]).toString();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_prototypevalueof"></a>`_.prototype.valueOf()`
|
||||
<a href="#_prototypevalueof">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4182 "View in source") [Ⓣ][1]
|
||||
<a href="#_prototypevalueof">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4152 "View in source") [Ⓣ][1]
|
||||
|
||||
Extracts the wrapped value.
|
||||
|
||||
@@ -832,7 +832,7 @@ _([1, 2, 3]).value();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_containscollection-target--fromindex0"></a>`_.contains(collection, target [, fromIndex=0])`
|
||||
<a href="#_containscollection-target--fromindex0">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1933 "View in source") [Ⓣ][1]
|
||||
<a href="#_containscollection-target--fromindex0">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1903 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if a given `target` element is present in a `collection` using strict equality for comparisons, i.e. `===`. If `fromIndex` is negative, it is used as the offset from the end of the collection.
|
||||
|
||||
@@ -870,7 +870,7 @@ _.contains('curly', 'ur');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_countbycollection-callbackproperty--thisarg"></a>`_.countBy(collection, callback|property [, thisArg])`
|
||||
<a href="#_countbycollection-callbackproperty--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1980 "View in source") [Ⓣ][1]
|
||||
<a href="#_countbycollection-callbackproperty--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1950 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an object composed of keys returned from running each element of `collection` through a `callback`. The corresponding value of each key is the number of times the key was returned by `callback`. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*. The `callback` argument may also be the name of a property to count by *(e.g. 'length')*.
|
||||
|
||||
@@ -902,7 +902,7 @@ _.countBy(['one', 'two', 'three'], 'length');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_everycollection--callbackidentity-thisarg"></a>`_.every(collection [, callback=identity, thisArg])`
|
||||
<a href="#_everycollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2009 "View in source") [Ⓣ][1]
|
||||
<a href="#_everycollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1979 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if the `callback` returns a truthy value for **all** elements of a `collection`. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*.
|
||||
|
||||
@@ -931,7 +931,7 @@ _.every([true, 1, null, 'yes'], Boolean);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_filtercollection--callbackidentity-thisarg"></a>`_.filter(collection [, callback=identity, thisArg])`
|
||||
<a href="#_filtercollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2048 "View in source") [Ⓣ][1]
|
||||
<a href="#_filtercollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2018 "View in source") [Ⓣ][1]
|
||||
|
||||
Examines each element in a `collection`, returning an array of all elements the `callback` returns truthy for. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*.
|
||||
|
||||
@@ -960,7 +960,7 @@ var evens = _.filter([1, 2, 3, 4, 5, 6], function(num) { return num % 2 == 0; })
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_findcollection--callbackidentity-thisarg"></a>`_.find(collection [, callback=identity, thisArg])`
|
||||
<a href="#_findcollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2092 "View in source") [Ⓣ][1]
|
||||
<a href="#_findcollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2062 "View in source") [Ⓣ][1]
|
||||
|
||||
Examines each element in a `collection`, returning the first one the `callback` returns truthy for. The function returns as soon as it finds an acceptable element, and does not iterate over the entire `collection`. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*.
|
||||
|
||||
@@ -989,7 +989,7 @@ var even = _.find([1, 2, 3, 4, 5, 6], function(num) { return num % 2 == 0; });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_foreachcollection--callbackidentity-thisarg"></a>`_.forEach(collection [, callback=identity, thisArg])`
|
||||
<a href="#_foreachcollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2126 "View in source") [Ⓣ][1]
|
||||
<a href="#_foreachcollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2096 "View in source") [Ⓣ][1]
|
||||
|
||||
Iterates over a `collection`, executing the `callback` for each element in the `collection`. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*. Callbacks may exit iteration early by explicitly returning `false`.
|
||||
|
||||
@@ -1021,7 +1021,7 @@ _.forEach({ 'one': 1, 'two': 2, 'three': 3 }, alert);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_groupbycollection-callbackproperty--thisarg"></a>`_.groupBy(collection, callback|property [, thisArg])`
|
||||
<a href="#_groupbycollection-callbackproperty--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2154 "View in source") [Ⓣ][1]
|
||||
<a href="#_groupbycollection-callbackproperty--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2124 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an object composed of keys returned from running each element of `collection` through a `callback`. The corresponding value of each key is an array of elements passed to `callback` that returned the key. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*. The `callback` argument may also be the name of a property to group by *(e.g. 'length')*.
|
||||
|
||||
@@ -1053,7 +1053,7 @@ _.groupBy(['one', 'two', 'three'], 'length');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_invokecollection-methodname--arg1-arg2-"></a>`_.invoke(collection, methodName [, arg1, arg2, ...])`
|
||||
<a href="#_invokecollection-methodname--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2186 "View in source") [Ⓣ][1]
|
||||
<a href="#_invokecollection-methodname--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2156 "View in source") [Ⓣ][1]
|
||||
|
||||
Invokes the method named by `methodName` on each element in the `collection`, returning an array of the results of each invoked method. Additional arguments will be passed to each invoked method. If `methodName` is a function it will be invoked for, and `this` bound to, each element in the `collection`.
|
||||
|
||||
@@ -1082,7 +1082,7 @@ _.invoke([123, 456], String.prototype.split, '');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_mapcollection--callbackidentity-thisarg"></a>`_.map(collection [, callback=identity, thisArg])`
|
||||
<a href="#_mapcollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2218 "View in source") [Ⓣ][1]
|
||||
<a href="#_mapcollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2188 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array of values by running each element in the `collection` through a `callback`. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*.
|
||||
|
||||
@@ -1114,7 +1114,7 @@ _.map({ 'one': 1, 'two': 2, 'three': 3 }, function(num) { return num * 3; });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_maxcollection--callback-thisarg"></a>`_.max(collection [, callback, thisArg])`
|
||||
<a href="#_maxcollection--callback-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2260 "View in source") [Ⓣ][1]
|
||||
<a href="#_maxcollection--callback-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2230 "View in source") [Ⓣ][1]
|
||||
|
||||
Retrieves the maximum value of an `array`. If `callback` is passed, it will be executed for each value in the `array` to generate the criterion by which the value is ranked. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index, collection)*.
|
||||
|
||||
@@ -1146,7 +1146,7 @@ _.max(stooges, function(stooge) { return stooge.age; });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_mincollection--callback-thisarg"></a>`_.min(collection [, callback, thisArg])`
|
||||
<a href="#_mincollection--callback-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2306 "View in source") [Ⓣ][1]
|
||||
<a href="#_mincollection--callback-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2276 "View in source") [Ⓣ][1]
|
||||
|
||||
Retrieves the minimum value of an `array`. If `callback` is passed, it will be executed for each value in the `array` to generate the criterion by which the value is ranked. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index, collection)*.
|
||||
|
||||
@@ -1172,7 +1172,7 @@ _.min([10, 5, 100, 2, 1000]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_pluckcollection-property"></a>`_.pluck(collection, property)`
|
||||
<a href="#_pluckcollection-property">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2355 "View in source") [Ⓣ][1]
|
||||
<a href="#_pluckcollection-property">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2325 "View in source") [Ⓣ][1]
|
||||
|
||||
Retrieves the value of a specified property from all elements in the `collection`.
|
||||
|
||||
@@ -1203,7 +1203,7 @@ _.pluck(stooges, 'name');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_reducecollection--callbackidentity-accumulator-thisarg"></a>`_.reduce(collection [, callback=identity, accumulator, thisArg])`
|
||||
<a href="#_reducecollection--callbackidentity-accumulator-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2379 "View in source") [Ⓣ][1]
|
||||
<a href="#_reducecollection--callbackidentity-accumulator-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2349 "View in source") [Ⓣ][1]
|
||||
|
||||
Boils down a `collection` to a single value. The initial state of the reduction is `accumulator` and each successive step of it should be returned by the `callback`. The `callback` is bound to `thisArg` and invoked with `4` arguments; for arrays they are *(accumulator, value, index|key, collection)*.
|
||||
|
||||
@@ -1233,7 +1233,7 @@ var sum = _.reduce([1, 2, 3], function(memo, num) { return memo + num; });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_reducerightcollection--callbackidentity-accumulator-thisarg"></a>`_.reduceRight(collection [, callback=identity, accumulator, thisArg])`
|
||||
<a href="#_reducerightcollection--callbackidentity-accumulator-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2408 "View in source") [Ⓣ][1]
|
||||
<a href="#_reducerightcollection--callbackidentity-accumulator-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2378 "View in source") [Ⓣ][1]
|
||||
|
||||
The right-associative version of `_.reduce`.
|
||||
|
||||
@@ -1264,7 +1264,7 @@ var flat = _.reduceRight(list, function(a, b) { return a.concat(b); }, []);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_rejectcollection--callbackidentity-thisarg"></a>`_.reject(collection [, callback=identity, thisArg])`
|
||||
<a href="#_rejectcollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2446 "View in source") [Ⓣ][1]
|
||||
<a href="#_rejectcollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2416 "View in source") [Ⓣ][1]
|
||||
|
||||
The opposite of `_.filter`, this method returns the values of a `collection` that `callback` does **not** return truthy for.
|
||||
|
||||
@@ -1290,7 +1290,7 @@ var odds = _.reject([1, 2, 3, 4, 5, 6], function(num) { return num % 2 == 0; });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_shufflecollection"></a>`_.shuffle(collection)`
|
||||
<a href="#_shufflecollection">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2467 "View in source") [Ⓣ][1]
|
||||
<a href="#_shufflecollection">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2437 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array of shuffled `array` values, using a version of the Fisher-Yates shuffle. See http://en.wikipedia.org/wiki/Fisher-Yates_shuffle.
|
||||
|
||||
@@ -1314,7 +1314,7 @@ _.shuffle([1, 2, 3, 4, 5, 6]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_sizecollection"></a>`_.size(collection)`
|
||||
<a href="#_sizecollection">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2499 "View in source") [Ⓣ][1]
|
||||
<a href="#_sizecollection">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2469 "View in source") [Ⓣ][1]
|
||||
|
||||
Gets the size of the `collection` by returning `collection.length` for arrays and array-like objects or the number of own enumerable properties for objects.
|
||||
|
||||
@@ -1344,7 +1344,7 @@ _.size('curly');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_somecollection--callbackidentity-thisarg"></a>`_.some(collection [, callback=identity, thisArg])`
|
||||
<a href="#_somecollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2524 "View in source") [Ⓣ][1]
|
||||
<a href="#_somecollection--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2494 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if the `callback` returns a truthy value for **any** element of a `collection`. The function returns as soon as it finds passing value, and does not iterate over the entire `collection`. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*.
|
||||
|
||||
@@ -1373,7 +1373,7 @@ _.some([null, 0, 'yes', false], Boolean);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_sortbycollection-callbackproperty--thisarg"></a>`_.sortBy(collection, callback|property [, thisArg])`
|
||||
<a href="#_sortbycollection-callbackproperty--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2570 "View in source") [Ⓣ][1]
|
||||
<a href="#_sortbycollection-callbackproperty--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2540 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array, stable sorted in ascending order by the results of running each element of `collection` through a `callback`. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, index|key, collection)*. The `callback` argument may also be the name of a property to sort by *(e.g. 'length')*.
|
||||
|
||||
@@ -1405,7 +1405,7 @@ _.sortBy(['larry', 'brendan', 'moe'], 'length');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_toarraycollection"></a>`_.toArray(collection)`
|
||||
<a href="#_toarraycollection">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2602 "View in source") [Ⓣ][1]
|
||||
<a href="#_toarraycollection">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2572 "View in source") [Ⓣ][1]
|
||||
|
||||
Converts the `collection` to an array.
|
||||
|
||||
@@ -1429,7 +1429,7 @@ Converts the `collection` to an array.
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_wherecollection-properties"></a>`_.where(collection, properties)`
|
||||
<a href="#_wherecollection-properties">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2633 "View in source") [Ⓣ][1]
|
||||
<a href="#_wherecollection-properties">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L2603 "View in source") [Ⓣ][1]
|
||||
|
||||
Examines each element in a `collection`, returning an array of all elements that contain the given `properties`.
|
||||
|
||||
@@ -1467,7 +1467,7 @@ _.where(stooges, { 'age': 40 });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_aftern-func"></a>`_.after(n, func)`
|
||||
<a href="#_aftern-func">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3266 "View in source") [Ⓣ][1]
|
||||
<a href="#_aftern-func">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3236 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that is restricted to executing `func` only after it is called `n` times. The `func` is executed with the `this` binding of the created function.
|
||||
|
||||
@@ -1495,7 +1495,7 @@ _.forEach(notes, function(note) {
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_bindfunc--thisarg-arg1-arg2-"></a>`_.bind(func [, thisArg, arg1, arg2, ...])`
|
||||
<a href="#_bindfunc--thisarg-arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3299 "View in source") [Ⓣ][1]
|
||||
<a href="#_bindfunc--thisarg-arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3269 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that, when called, invokes `func` with the `this` binding of `thisArg` and prepends any additional `bind` arguments to those passed to the bound function.
|
||||
|
||||
@@ -1526,7 +1526,7 @@ func();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_bindallobject--methodname1-methodname2-"></a>`_.bindAll(object [, methodName1, methodName2, ...])`
|
||||
<a href="#_bindallobject--methodname1-methodname2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3329 "View in source") [Ⓣ][1]
|
||||
<a href="#_bindallobject--methodname1-methodname2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3299 "View in source") [Ⓣ][1]
|
||||
|
||||
Binds methods on `object` to `object`, overwriting the existing method. If no method names are provided, all the function properties of `object` will be bound.
|
||||
|
||||
@@ -1557,7 +1557,7 @@ jQuery('#lodash_button').on('click', buttonView.onClick);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_bindkeyobject-key--arg1-arg2-"></a>`_.bindKey(object, key [, arg1, arg2, ...])`
|
||||
<a href="#_bindkeyobject-key--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3375 "View in source") [Ⓣ][1]
|
||||
<a href="#_bindkeyobject-key--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3345 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that, when called, invokes the method at `object[key]` and prepends any additional `bindKey` arguments to those passed to the bound function. This method differs from `_.bind` by allowing bound functions to reference methods that will be redefined or don't yet exist. See http://michaux.ca/articles/lazy-function-definition-pattern.
|
||||
|
||||
@@ -1598,7 +1598,7 @@ func();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_composefunc1-func2-"></a>`_.compose([func1, func2, ...])`
|
||||
<a href="#_composefunc1-func2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3398 "View in source") [Ⓣ][1]
|
||||
<a href="#_composefunc1-func2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3368 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that is the composition of the passed functions, where each function consumes the return value of the function that follows. In math terms, composing the functions `f()`, `g()`, and `h()` produces `f(g(h()))`. Each function is executed with the `this` binding of the composed function.
|
||||
|
||||
@@ -1625,7 +1625,7 @@ welcome('moe');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_debouncefunc-wait-immediate"></a>`_.debounce(func, wait, immediate)`
|
||||
<a href="#_debouncefunc-wait-immediate">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3431 "View in source") [Ⓣ][1]
|
||||
<a href="#_debouncefunc-wait-immediate">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3401 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that will delay the execution of `func` until after `wait` milliseconds have elapsed since the last time it was invoked. Pass `true` for `immediate` to cause debounce to invoke `func` on the leading, instead of the trailing, edge of the `wait` timeout. Subsequent calls to the debounced function will return the result of the last `func` call.
|
||||
|
||||
@@ -1651,7 +1651,7 @@ jQuery(window).on('resize', lazyLayout);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_deferfunc--arg1-arg2-"></a>`_.defer(func [, arg1, arg2, ...])`
|
||||
<a href="#_deferfunc--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3495 "View in source") [Ⓣ][1]
|
||||
<a href="#_deferfunc--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3465 "View in source") [Ⓣ][1]
|
||||
|
||||
Defers executing the `func` function until the current call stack has cleared. Additional arguments will be passed to `func` when it is invoked.
|
||||
|
||||
@@ -1676,7 +1676,7 @@ _.defer(function() { alert('deferred'); });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_delayfunc-wait--arg1-arg2-"></a>`_.delay(func, wait [, arg1, arg2, ...])`
|
||||
<a href="#_delayfunc-wait--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3475 "View in source") [Ⓣ][1]
|
||||
<a href="#_delayfunc-wait--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3445 "View in source") [Ⓣ][1]
|
||||
|
||||
Executes the `func` function after `wait` milliseconds. Additional arguments will be passed to `func` when it is invoked.
|
||||
|
||||
@@ -1703,7 +1703,7 @@ _.delay(log, 1000, 'logged later');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_memoizefunc--resolver"></a>`_.memoize(func [, resolver])`
|
||||
<a href="#_memoizefunc--resolver">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3519 "View in source") [Ⓣ][1]
|
||||
<a href="#_memoizefunc--resolver">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3489 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that memoizes the result of `func`. If `resolver` is passed, it will be used to determine the cache key for storing the result based on the arguments passed to the memoized function. By default, the first argument passed to the memoized function is used as the cache key. The `func` is executed with the `this` binding of the memoized function.
|
||||
|
||||
@@ -1729,7 +1729,7 @@ var fibonacci = _.memoize(function(n) {
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_oncefunc"></a>`_.once(func)`
|
||||
<a href="#_oncefunc">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3546 "View in source") [Ⓣ][1]
|
||||
<a href="#_oncefunc">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3516 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that is restricted to execute `func` once. Repeat calls to the function will return the value of the first call. The `func` is executed with the `this` binding of the created function.
|
||||
|
||||
@@ -1755,7 +1755,7 @@ initialize();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_partialfunc--arg1-arg2-"></a>`_.partial(func [, arg1, arg2, ...])`
|
||||
<a href="#_partialfunc--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3581 "View in source") [Ⓣ][1]
|
||||
<a href="#_partialfunc--arg1-arg2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3551 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that, when called, invokes `func` with any additional `partial` arguments prepended to those passed to the new function. This method is similar to `bind`, except it does **not** alter the `this` binding.
|
||||
|
||||
@@ -1782,7 +1782,7 @@ hi('moe');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_throttlefunc-wait"></a>`_.throttle(func, wait)`
|
||||
<a href="#_throttlefunc-wait">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3603 "View in source") [Ⓣ][1]
|
||||
<a href="#_throttlefunc-wait">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3573 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that, when executed, will only call the `func` function at most once per every `wait` milliseconds. If the throttled function is invoked more than once during the `wait` timeout, `func` will also be called on the trailing edge of the timeout. Subsequent calls to the throttled function will return the result of the last `func` call.
|
||||
|
||||
@@ -1807,7 +1807,7 @@ jQuery(window).on('scroll', throttled);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_wrapvalue-wrapper"></a>`_.wrap(value, wrapper)`
|
||||
<a href="#_wrapvalue-wrapper">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3655 "View in source") [Ⓣ][1]
|
||||
<a href="#_wrapvalue-wrapper">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3625 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a function that passes `value` to the `wrapper` function as its first argument. Additional arguments passed to the function are appended to those passed to the `wrapper` function. The `wrapper` is executed with the `this` binding of the created function.
|
||||
|
||||
@@ -1843,7 +1843,7 @@ hello();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_assignobject--source1-source2-"></a>`_.assign(object [, source1, source2, ...])`
|
||||
<a href="#_assignobject--source1-source2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L816 "View in source") [Ⓣ][1]
|
||||
<a href="#_assignobject--source1-source2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L786 "View in source") [Ⓣ][1]
|
||||
|
||||
Assigns own enumerable properties of source object(s) to the `destination` object. Subsequent sources will overwrite propery assignments of previous sources.
|
||||
|
||||
@@ -1871,7 +1871,7 @@ _.assign({ 'name': 'moe' }, { 'age': 40 });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_clonevalue-deep"></a>`_.clone(value, deep)`
|
||||
<a href="#_clonevalue-deep">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1015 "View in source") [Ⓣ][1]
|
||||
<a href="#_clonevalue-deep">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L985 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a clone of `value`. If `deep` is `true`, all nested objects will also be cloned, otherwise they will be assigned by reference. Functions and DOM nodes are **not** cloned. The enumerable properties of `arguments` objects and objects created by constructors other than `Object` are cloned to plain Object objects. Note: Lo-Dash's deep clone functionality is loosely based on the structured clone algorithm. See http://www.w3.org/TR/html5/common-dom-interfaces.html#internal-structured-cloning-algorithm.
|
||||
|
||||
@@ -1910,7 +1910,7 @@ shallow[0] === stooges[0];
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_defaultsobject--default1-default2-"></a>`_.defaults(object [, default1, default2, ...])`
|
||||
<a href="#_defaultsobject--default1-default2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1103 "View in source") [Ⓣ][1]
|
||||
<a href="#_defaultsobject--default1-default2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1073 "View in source") [Ⓣ][1]
|
||||
|
||||
Assigns own enumerable properties of source object(s) to the `destination` object for all `destination` properties that resolve to `null`/`undefined`. Once a property is set, additional defaults of the same property will be ignored.
|
||||
|
||||
@@ -1936,7 +1936,7 @@ _.defaults(iceCream, { 'flavor': 'vanilla', 'sprinkles': 'rainbow' });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_forinobject--callbackidentity-thisarg"></a>`_.forIn(object [, callback=identity, thisArg])`
|
||||
<a href="#_forinobject--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L872 "View in source") [Ⓣ][1]
|
||||
<a href="#_forinobject--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L842 "View in source") [Ⓣ][1]
|
||||
|
||||
Iterates over `object`'s own and inherited enumerable properties, executing the `callback` for each property. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, key, object)*. Callbacks may exit iteration early by explicitly returning `false`.
|
||||
|
||||
@@ -1972,7 +1972,7 @@ _.forIn(new Dog('Dagny'), function(value, key) {
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_forownobject--callbackidentity-thisarg"></a>`_.forOwn(object [, callback=identity, thisArg])`
|
||||
<a href="#_forownobject--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L896 "View in source") [Ⓣ][1]
|
||||
<a href="#_forownobject--callbackidentity-thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L866 "View in source") [Ⓣ][1]
|
||||
|
||||
Iterates over an object's own enumerable properties, executing the `callback` for each property. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, key, object)*. Callbacks may exit iteration early by explicitly returning `false`.
|
||||
|
||||
@@ -2000,7 +2000,7 @@ _.forOwn({ '0': 'zero', '1': 'one', 'length': 2 }, function(num, key) {
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_functionsobject"></a>`_.functions(object)`
|
||||
<a href="#_functionsobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1122 "View in source") [Ⓣ][1]
|
||||
<a href="#_functionsobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1092 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a sorted array of all enumerable properties, own and inherited, of `object` that have function values.
|
||||
|
||||
@@ -2027,7 +2027,7 @@ _.functions(_);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_hasobject-property"></a>`_.has(object, property)`
|
||||
<a href="#_hasobject-property">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1147 "View in source") [Ⓣ][1]
|
||||
<a href="#_hasobject-property">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1117 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if the specified object `property` exists and is a direct property, instead of an inherited property.
|
||||
|
||||
@@ -2052,7 +2052,7 @@ _.has({ 'a': 1, 'b': 2, 'c': 3 }, 'b');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_invertobject"></a>`_.invert(object)`
|
||||
<a href="#_invertobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1164 "View in source") [Ⓣ][1]
|
||||
<a href="#_invertobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1134 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an object composed of the inverted keys and values of the given `object`.
|
||||
|
||||
@@ -2076,7 +2076,7 @@ _.invert({ 'first': 'Moe', 'second': 'Larry', 'third': 'Curly' });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isargumentsvalue"></a>`_.isArguments(value)`
|
||||
<a href="#_isargumentsvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L834 "View in source") [Ⓣ][1]
|
||||
<a href="#_isargumentsvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L804 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is an `arguments` object.
|
||||
|
||||
@@ -2103,7 +2103,7 @@ _.isArguments([1, 2, 3]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isarrayvalue"></a>`_.isArray(value)`
|
||||
<a href="#_isarrayvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1188 "View in source") [Ⓣ][1]
|
||||
<a href="#_isarrayvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1158 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is an array.
|
||||
|
||||
@@ -2130,7 +2130,7 @@ _.isArray([1, 2, 3]);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isbooleanvalue"></a>`_.isBoolean(value)`
|
||||
<a href="#_isbooleanvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1205 "View in source") [Ⓣ][1]
|
||||
<a href="#_isbooleanvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1175 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is a boolean *(`true` or `false`)* value.
|
||||
|
||||
@@ -2154,7 +2154,7 @@ _.isBoolean(null);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isdatevalue"></a>`_.isDate(value)`
|
||||
<a href="#_isdatevalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1222 "View in source") [Ⓣ][1]
|
||||
<a href="#_isdatevalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1192 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is a date.
|
||||
|
||||
@@ -2178,7 +2178,7 @@ _.isDate(new Date);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_iselementvalue"></a>`_.isElement(value)`
|
||||
<a href="#_iselementvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1239 "View in source") [Ⓣ][1]
|
||||
<a href="#_iselementvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1209 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is a DOM element.
|
||||
|
||||
@@ -2202,7 +2202,7 @@ _.isElement(document.body);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isemptyvalue"></a>`_.isEmpty(value)`
|
||||
<a href="#_isemptyvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1264 "View in source") [Ⓣ][1]
|
||||
<a href="#_isemptyvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1234 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is empty. Arrays, strings, or `arguments` objects with a length of `0` and objects with no own enumerable properties are considered "empty".
|
||||
|
||||
@@ -2232,7 +2232,7 @@ _.isEmpty('');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isequala-b"></a>`_.isEqual(a, b)`
|
||||
<a href="#_isequala-b">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1306 "View in source") [Ⓣ][1]
|
||||
<a href="#_isequala-b">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1276 "View in source") [Ⓣ][1]
|
||||
|
||||
Performs a deep comparison between two values to determine if they are equivalent to each other.
|
||||
|
||||
@@ -2263,7 +2263,7 @@ _.isEqual(moe, clone);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isfinitevalue"></a>`_.isFinite(value)`
|
||||
<a href="#_isfinitevalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1457 "View in source") [Ⓣ][1]
|
||||
<a href="#_isfinitevalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1427 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is, or can be coerced to, a finite number. Note: This is not the same as native `isFinite`, which will return true for booleans and empty strings. See http://es5.github.com/#x15.1.2.5.
|
||||
|
||||
@@ -2299,7 +2299,7 @@ _.isFinite(Infinity);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isfunctionvalue"></a>`_.isFunction(value)`
|
||||
<a href="#_isfunctionvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1474 "View in source") [Ⓣ][1]
|
||||
<a href="#_isfunctionvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1444 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is a function.
|
||||
|
||||
@@ -2323,7 +2323,7 @@ _.isFunction(_);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isnanvalue"></a>`_.isNaN(value)`
|
||||
<a href="#_isnanvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1537 "View in source") [Ⓣ][1]
|
||||
<a href="#_isnanvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1507 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is `NaN`. Note: This is not the same as native `isNaN`, which will return `true` for `undefined` and other values. See http://es5.github.com/#x15.1.2.4.
|
||||
|
||||
@@ -2356,7 +2356,7 @@ _.isNaN(undefined);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isnullvalue"></a>`_.isNull(value)`
|
||||
<a href="#_isnullvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1559 "View in source") [Ⓣ][1]
|
||||
<a href="#_isnullvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1529 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is `null`.
|
||||
|
||||
@@ -2383,7 +2383,7 @@ _.isNull(undefined);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isnumbervalue"></a>`_.isNumber(value)`
|
||||
<a href="#_isnumbervalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1576 "View in source") [Ⓣ][1]
|
||||
<a href="#_isnumbervalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1546 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is a number.
|
||||
|
||||
@@ -2407,7 +2407,7 @@ _.isNumber(8.4 * 5);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isobjectvalue"></a>`_.isObject(value)`
|
||||
<a href="#_isobjectvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1504 "View in source") [Ⓣ][1]
|
||||
<a href="#_isobjectvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1474 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is the language type of Object. *(e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)*
|
||||
|
||||
@@ -2437,7 +2437,7 @@ _.isObject(1);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isplainobjectvalue"></a>`_.isPlainObject(value)`
|
||||
<a href="#_isplainobjectvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1604 "View in source") [Ⓣ][1]
|
||||
<a href="#_isplainobjectvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1574 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if a given `value` is an object created by the `Object` constructor.
|
||||
|
||||
@@ -2472,7 +2472,7 @@ _.isPlainObject({ 'name': 'moe', 'age': 40 });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isregexpvalue"></a>`_.isRegExp(value)`
|
||||
<a href="#_isregexpvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1629 "View in source") [Ⓣ][1]
|
||||
<a href="#_isregexpvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1599 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is a regular expression.
|
||||
|
||||
@@ -2496,7 +2496,7 @@ _.isRegExp(/moe/);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isstringvalue"></a>`_.isString(value)`
|
||||
<a href="#_isstringvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1646 "View in source") [Ⓣ][1]
|
||||
<a href="#_isstringvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1616 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is a string.
|
||||
|
||||
@@ -2520,7 +2520,7 @@ _.isString('moe');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_isundefinedvalue"></a>`_.isUndefined(value)`
|
||||
<a href="#_isundefinedvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1663 "View in source") [Ⓣ][1]
|
||||
<a href="#_isundefinedvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1633 "View in source") [Ⓣ][1]
|
||||
|
||||
Checks if `value` is `undefined`.
|
||||
|
||||
@@ -2544,7 +2544,7 @@ _.isUndefined(void 0);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_keysobject"></a>`_.keys(object)`
|
||||
<a href="#_keysobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1680 "View in source") [Ⓣ][1]
|
||||
<a href="#_keysobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1650 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array composed of the own enumerable property names of `object`.
|
||||
|
||||
@@ -2568,7 +2568,7 @@ _.keys({ 'one': 1, 'two': 2, 'three': 3 });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_mergeobject--source1-source2-"></a>`_.merge(object [, source1, source2, ...])`
|
||||
<a href="#_mergeobject--source1-source2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1718 "View in source") [Ⓣ][1]
|
||||
<a href="#_mergeobject--source1-source2-">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1688 "View in source") [Ⓣ][1]
|
||||
|
||||
Merges enumerable properties of the source object(s) into the `destination` object. Subsequent sources will overwrite propery assignments of previous sources.
|
||||
|
||||
@@ -2603,7 +2603,7 @@ _.merge(stooges, ages);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_omitobject-callback-prop1-prop2--thisarg"></a>`_.omit(object, callback|[prop1, prop2, ..., thisArg])`
|
||||
<a href="#_omitobject-callback-prop1-prop2--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1792 "View in source") [Ⓣ][1]
|
||||
<a href="#_omitobject-callback-prop1-prop2--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1762 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a shallow clone of `object` excluding the specified properties. Property names may be specified as individual arguments or as arrays of property names. If `callback` is passed, it will be executed for each property in the `object`, omitting the properties `callback` returns truthy for. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, key, object)*.
|
||||
|
||||
@@ -2634,7 +2634,7 @@ _.omit({ 'name': 'moe', '_hint': 'knucklehead', '_seed': '96c4eb' }, function(va
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_pairsobject"></a>`_.pairs(object)`
|
||||
<a href="#_pairsobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1826 "View in source") [Ⓣ][1]
|
||||
<a href="#_pairsobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1796 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a two dimensional array of the given object's key-value pairs, i.e. `[[key1, value1], [key2, value2]]`.
|
||||
|
||||
@@ -2658,7 +2658,7 @@ _.pairs({ 'moe': 30, 'larry': 40, 'curly': 50 });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_pickobject-callback-prop1-prop2--thisarg"></a>`_.pick(object, callback|[prop1, prop2, ..., thisArg])`
|
||||
<a href="#_pickobject-callback-prop1-prop2--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1859 "View in source") [Ⓣ][1]
|
||||
<a href="#_pickobject-callback-prop1-prop2--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1829 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates a shallow clone of `object` composed of the specified properties. Property names may be specified as individual arguments or as arrays of property names. If `callback` is passed, it will be executed for each property in the `object`, picking the properties `callback` returns truthy for. The `callback` is bound to `thisArg` and invoked with three arguments; *(value, key, object)*.
|
||||
|
||||
@@ -2689,7 +2689,7 @@ _.pick({ 'name': 'moe', '_hint': 'knucklehead', '_seed': '96c4eb' }, function(va
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_valuesobject"></a>`_.values(object)`
|
||||
<a href="#_valuesobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1896 "View in source") [Ⓣ][1]
|
||||
<a href="#_valuesobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L1866 "View in source") [Ⓣ][1]
|
||||
|
||||
Creates an array composed of the own enumerable property values of `object`.
|
||||
|
||||
@@ -2720,7 +2720,7 @@ _.values({ 'one': 1, 'two': 2, 'three': 3 });
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_escapestring"></a>`_.escape(string)`
|
||||
<a href="#_escapestring">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3679 "View in source") [Ⓣ][1]
|
||||
<a href="#_escapestring">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3649 "View in source") [Ⓣ][1]
|
||||
|
||||
Converts the characters `&`, `<`, `>`, `"`, and `'` in `string` to their corresponding HTML entities.
|
||||
|
||||
@@ -2744,7 +2744,7 @@ _.escape('Moe, Larry & Curly');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_identityvalue"></a>`_.identity(value)`
|
||||
<a href="#_identityvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3699 "View in source") [Ⓣ][1]
|
||||
<a href="#_identityvalue">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3669 "View in source") [Ⓣ][1]
|
||||
|
||||
This function returns the first argument passed to it. Note: This function is used throughout Lo-Dash as a default callback.
|
||||
|
||||
@@ -2769,7 +2769,7 @@ moe === _.identity(moe);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_mixinobject"></a>`_.mixin(object)`
|
||||
<a href="#_mixinobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3725 "View in source") [Ⓣ][1]
|
||||
<a href="#_mixinobject">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3695 "View in source") [Ⓣ][1]
|
||||
|
||||
Adds functions properties of `object` to the `lodash` function and chainable wrapper.
|
||||
|
||||
@@ -2799,7 +2799,7 @@ _('curly').capitalize();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_noconflict"></a>`_.noConflict()`
|
||||
<a href="#_noconflict">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3751 "View in source") [Ⓣ][1]
|
||||
<a href="#_noconflict">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3721 "View in source") [Ⓣ][1]
|
||||
|
||||
Reverts the '_' variable to its previous value and returns a reference to the `lodash` function.
|
||||
|
||||
@@ -2819,7 +2819,7 @@ var lodash = _.noConflict();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_randommin0-max1"></a>`_.random([min=0, max=1])`
|
||||
<a href="#_randommin0-max1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3774 "View in source") [Ⓣ][1]
|
||||
<a href="#_randommin0-max1">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3744 "View in source") [Ⓣ][1]
|
||||
|
||||
Produces a random number between `min` and `max` *(inclusive)*. If only one argument is passed, a number between `0` and the given number will be returned.
|
||||
|
||||
@@ -2847,7 +2847,7 @@ _.random(5);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_resultobject-property"></a>`_.result(object, property)`
|
||||
<a href="#_resultobject-property">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3812 "View in source") [Ⓣ][1]
|
||||
<a href="#_resultobject-property">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3782 "View in source") [Ⓣ][1]
|
||||
|
||||
Resolves the value of `property` on `object`. If `property` is a function it will be invoked and its result returned, else the property value is returned. If `object` is falsey, then `null` is returned.
|
||||
|
||||
@@ -2882,7 +2882,7 @@ _.result(object, 'stuff');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_templatetext-data-options"></a>`_.template(text, data, options)`
|
||||
<a href="#_templatetext-data-options">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3897 "View in source") [Ⓣ][1]
|
||||
<a href="#_templatetext-data-options">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3867 "View in source") [Ⓣ][1]
|
||||
|
||||
A micro-templating method that handles arbitrary delimiters, preserves whitespace, and correctly escapes quotes within interpolated code. Note: In the development build `_.template` utilizes sourceURLs for easier debugging. See http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/#toc-sourceurl Note: Lo-Dash may be used in Chrome extensions by either creating a `lodash csp` build and avoiding `_.template` use, or loading Lo-Dash in a sandboxed page. See http://developer.chrome.com/trunk/extensions/sandboxingEval.html
|
||||
|
||||
@@ -2956,7 +2956,7 @@ fs.writeFileSync(path.join(cwd, 'jst.js'), '\
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_timesn-callback--thisarg"></a>`_.times(n, callback [, thisArg])`
|
||||
<a href="#_timesn-callback--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4028 "View in source") [Ⓣ][1]
|
||||
<a href="#_timesn-callback--thisarg">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L3998 "View in source") [Ⓣ][1]
|
||||
|
||||
Executes the `callback` function `n` times, returning an array of the results of each `callback` execution. The `callback` is bound to `thisArg` and invoked with one argument; *(index)*.
|
||||
|
||||
@@ -2988,7 +2988,7 @@ _.times(3, function(n) { this.cast(n); }, mage);
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_unescapestring"></a>`_.unescape(string)`
|
||||
<a href="#_unescapestring">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4054 "View in source") [Ⓣ][1]
|
||||
<a href="#_unescapestring">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4024 "View in source") [Ⓣ][1]
|
||||
|
||||
The opposite of `_.escape`, this method converts the HTML entities `&`, `<`, `>`, `"`, and `'` in `string` to their corresponding characters.
|
||||
|
||||
@@ -3012,7 +3012,7 @@ _.unescape('Moe, Larry & Curly');
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_uniqueidprefix"></a>`_.uniqueId([prefix])`
|
||||
<a href="#_uniqueidprefix">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4074 "View in source") [Ⓣ][1]
|
||||
<a href="#_uniqueidprefix">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4044 "View in source") [Ⓣ][1]
|
||||
|
||||
Generates a unique ID. If `prefix` is passed, the ID will be appended to it.
|
||||
|
||||
@@ -3046,7 +3046,7 @@ _.uniqueId();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_version"></a>`_.VERSION`
|
||||
<a href="#_version">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4195 "View in source") [Ⓣ][1]
|
||||
<a href="#_version">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L4165 "View in source") [Ⓣ][1]
|
||||
|
||||
*(String)*: The semantic version number.
|
||||
|
||||
@@ -3058,7 +3058,7 @@ _.uniqueId();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_templatesettings"></a>`_.templateSettings`
|
||||
<a href="#_templatesettings">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L280 "View in source") [Ⓣ][1]
|
||||
<a href="#_templatesettings">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L275 "View in source") [Ⓣ][1]
|
||||
|
||||
*(Object)*: By default, the template delimiters used by Lo-Dash are similar to those in embedded Ruby *(ERB)*. Change the following template settings to use alternative delimiters.
|
||||
|
||||
@@ -3070,7 +3070,7 @@ _.uniqueId();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_templatesettingsescape"></a>`_.templateSettings.escape`
|
||||
<a href="#_templatesettingsescape">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L289 "View in source") [Ⓣ][1]
|
||||
<a href="#_templatesettingsescape">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L284 "View in source") [Ⓣ][1]
|
||||
|
||||
*(RegExp)*: Used to detect `data` property values to be HTML-escaped.
|
||||
|
||||
@@ -3082,7 +3082,7 @@ _.uniqueId();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_templatesettingsevaluate"></a>`_.templateSettings.evaluate`
|
||||
<a href="#_templatesettingsevaluate">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L298 "View in source") [Ⓣ][1]
|
||||
<a href="#_templatesettingsevaluate">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L293 "View in source") [Ⓣ][1]
|
||||
|
||||
*(RegExp)*: Used to detect code to be evaluated.
|
||||
|
||||
@@ -3094,7 +3094,7 @@ _.uniqueId();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_templatesettingsinterpolate"></a>`_.templateSettings.interpolate`
|
||||
<a href="#_templatesettingsinterpolate">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L307 "View in source") [Ⓣ][1]
|
||||
<a href="#_templatesettingsinterpolate">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L302 "View in source") [Ⓣ][1]
|
||||
|
||||
*(RegExp)*: Used to detect `data` property values to inject.
|
||||
|
||||
@@ -3106,7 +3106,7 @@ _.uniqueId();
|
||||
<!-- div -->
|
||||
|
||||
### <a id="_templatesettingsvariable"></a>`_.templateSettings.variable`
|
||||
<a href="#_templatesettingsvariable">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L316 "View in source") [Ⓣ][1]
|
||||
<a href="#_templatesettingsvariable">#</a> [Ⓢ](https://github.com/bestiejs/lodash/blob/master/lodash.js#L311 "View in source") [Ⓣ][1]
|
||||
|
||||
*(String)*: Used to reference the data object in the template text.
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
// generate Markdown
|
||||
$markdown = docdown(array(
|
||||
'path' => '../' . $file,
|
||||
'title' => 'Lo-Dash <sup>v0.10.0</sup>',
|
||||
'title' => 'Lo-Dash <sup>v1.0.0-rc.1</sup>',
|
||||
'toc' => 'categories',
|
||||
'url' => 'https://github.com/bestiejs/lodash/blob/master/lodash.js'
|
||||
));
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*!
|
||||
* Lo-Dash 0.10.0 <http://lodash.com>
|
||||
* Lo-Dash 1.0.0-rc.1 <http://lodash.com>
|
||||
* (c) 2012 John-David Dalton <http://allyoucanleet.com/>
|
||||
* Based on Underscore.js 1.4.2 <http://underscorejs.org>
|
||||
* (c) 2009-2012 Jeremy Ashkenas, DocumentCloud Inc.
|
||||
@@ -4162,7 +4162,7 @@
|
||||
* @memberOf _
|
||||
* @type String
|
||||
*/
|
||||
lodash.VERSION = '0.10.0';
|
||||
lodash.VERSION = '1.0.0-rc.1';
|
||||
|
||||
// assign static methods
|
||||
lodash.assign = assign;
|
||||
|
||||
77
lodash.min.js
vendored
77
lodash.min.js
vendored
@@ -1,42 +1,41 @@
|
||||
/*!
|
||||
Lo-Dash 0.10.0 lodash.com/license
|
||||
Lo-Dash 1.0.0-rc.1 lodash.com/license
|
||||
Underscore.js 1.4.2 underscorejs.org/LICENSE
|
||||
*/
|
||||
;(function(e,t){function s(t,r){var i,s=e.onerror,o=e._,u=et.createElement("script"),a=et.scripts[0];e.onerror=function(e){return i=e,n},u.text="var _=function("+t+"){"+r+"\n}",a.parentNode.insertBefore(u,a).parentNode.removeChild(u),u=e._,e._=o,e.onerror=s;if(i)throw new SyntaxError(i);return u}function o(e){if(e&&"object"==typeof e&&e.__wrapped__)return e;if(!(this instanceof o))return new o(e);this.__wrapped__=e}function u(e,t,n){t||(t=0);var r=e.length,i=r-t>=(n||ot);if(i)for(var s={},n=t-1;++
|
||||
n<r;){var o=e[n]+"";(Ct.call(s,o)?s[o]:s[o]=[]).push(e[n])}return function(n){if(i){var r=n+"";return Ct.call(s,r)&&-1<W(s[r],n)}return-1<W(e,n,t)}}function a(e){return e.charCodeAt(0)}function f(e,t){var n=e.b,r=t.b,e=e.a,t=t.a;if(e!==t){if(e>t||"undefined"==typeof e)return 1;if(e<t||"undefined"==typeof t)return-1}return n<r?-1:1}function l(e,t,n){function i(){var r=arguments,a=o?this:t;return s||(e=t[u]),n.length&&(r=r.length?n.concat(g(r)):n),this instanceof i?(r=e.apply(this,r),k(r)?r:this):e
|
||||
.apply(a,r)}var s=C(e),o=!n,u=t;return o&&(n=t),s||(t=e),e&&e.prototype&&(m.prototype=e.prototype,i.prototype=new m,m.prototype=r),i}function c(e,t){return e?"function"!=typeof e?function(t){return t[e]}:"undefined"!=typeof t?function(n,r,i){return e.call(t,n,r,i)}:e:K}function h(){for(var e={b:"",c:"",e:Vt,f:tn,g:"",h:Kt,i:Gt,j:Et,k:"",l:n},t,r=0;t=arguments[r];r++)for(var i in t)e[i]=t[i];t=e.a,e.d=/^[^,]+/.exec(t)[0],r="var i,l="+e.d+",t="+e.d+";if(!"+e.d+")return t;"+e.k+";",e.b?(r+="var m=l.length;i=-1;if(typeof m=='number'){"
|
||||
,e.i&&(r+="if(k(l)){l=l.split('')}"),r+="while(++i<m){"+e.b+"}}else {"):e.h&&(r+="var m=l.length;i=-1;if(m&&j(l)){while(++i<m){i+='';"+e.g+"}}else {"),e.e||(r+="var u=typeof l=='function'&&s.call(l,'prototype');");if(e.f&&e.l)r+="var q=-1,r=p[typeof l]?n(l):[],m=r.length;while(++q<m){i=r[q];",e.e||(r+="if(!(u&&i=='prototype')){"),r+=e.g+"",e.e||(r+="}");else{r+="for(i in l){";if(!e.e||e.l)r+="if(",e.e||(r+="!(u&&i=='prototype')"),!e.e&&e.l&&(r+="&&"),e.l&&(r+="h.call(l,i)"),r+="){";r+=e.g+";";if(!
|
||||
e.e||e.l)r+="}"}r+="}";if(e.e){r+="var f=l.constructor;";for(i=0;7>i;i++)r+="i='"+e.j[i]+"';if(","constructor"==e.j[i]&&(r+="!(f&&f.prototype===l)&&"),r+="h.call(l,i)){"+e.g+"}"}if(e.b||e.h)r+="}";return r+=e.c+";return t",s("e,h,j,k,p,n,s","return function("+t+"){"+r+"}")(c,Ct,b,A,sn,Pt,Lt)}function p(e){return"\\"+on[e]}function d(e){return dn[e]}function v(e){return"function"!=typeof e.toString&&"string"==typeof (e+"")}function m(){}function g(e,t,n){t||(t=0),"undefined"==typeof n&&(n=e?e.length
|
||||
:0);for(var r=-1,n=n-t||0,i=Array(0>n?0:n);++r<n;)i[r]=e[t+r];return i}function y(e){return vn[e]}function b(e){return At.call(e)==Ft}function w(e){var t=i;if(!e||"object"!=typeof e||b(e))return t;var n=e.constructor;return!C(n)&&(!Yt||!v(e))||n instanceof n?$t?(hn(e,function(e,n,r){return t=!Ct.call(r,n),i}),t===i):(hn(e,function(e,n){t=n}),t===i||Ct.call(e,t)):t}function E(e){var t=[];return pn(e,function(e,n){t.push(n)}),t}function S(e,t,n,s,o){if(e==r)return e;n&&(t=i);if(n=k(e)){var u=At.call
|
||||
(e);if(!nn[u]||Yt&&v(e))return e;var a=gn(e)}if(!n||!t)return n?a?g(e):cn({},e):e;n=rn[u];switch(u){case qt:case Rt:return new n(+e);case Ut:case Xt:return new n(e);case Wt:return n(e.source,pt.exec(e))}s||(s=[]),o||(o=[]);for(u=s.length;u--;)if(s[u]==e)return o[u];var f=a?n(e.length):{};return s.push(e),o.push(f),(a?wn:pn)(e,function(e,n){f[n]=S(e,t,r,s,o)}),a&&(Ct.call(e,"index")&&(f.index=e.index),Ct.call(e,"input")&&(f.input=e.input)),f}function x(e){var t=[];return hn(e,function(e,n){C(e)&&t
|
||||
.push(n)}),t.sort()}function T(e){var t={};return pn(e,function(e,n){t[e]=n}),t}function N(e,t,s,o){if(e===t)return 0!==e||1/e==1/t;if(e==r||t==r)return e===t;var u=At.call(e),a=At.call(t);u==Ft&&(u=zt),a==Ft&&(a=zt);if(u!=a)return i;switch(u){case qt:case Rt:return+e==+t;case Ut:return e!=+e?t!=+t:0==e?1/e==1/t:e==+t;case Wt:case Xt:return e==t+""}a=u==It;if(!a){if(e.__wrapped__||t.__wrapped__)return N(e.__wrapped__||e,t.__wrapped__||t);if(u!=zt||Yt&&(v(e)||v(t)))return i;var u=e.constructor,f=t
|
||||
.constructor;if(u!=f&&(!C(u)||!(u instanceof u&&C(f)&&f instanceof f)))return i}s||(s=[]),o||(o=[]);for(u=s.length;u--;)if(s[u]==e)return o[u]==t;var l=n,c=0;s.push(e),o.push(t);if(a){c=e.length;if(l=c==t.length)for(;c--&&(l=N(e[c],t[c],s,o)););return l}return hn(e,function(e,n,r){if(Ct.call(r,n))return c++,l=Ct.call(t,n)&&N(e,t[n],s,o)}),l&&hn(t,function(e,t,n){if(Ct.call(n,t))return l=-1<--c}),l}function C(e){return"function"==typeof e}function k(e){return e?sn[typeof e]:i}function L(e){return"number"==typeof
|
||||
e||At.call(e)==Ut}function A(e){return"string"==typeof e||At.call(e)==Xt}function O(e,t,n){var i=arguments,s=0,o=2,u=i[3],a=i[4];n!==st&&(u=[],a=[],"number"!=typeof n&&(o=i.length));for(;++s<o;)pn(i[s],function(t,n){var i,s,o;if(t&&((s=gn(t))||yn(t))){for(var f=u.length;f--;)if(i=u[f]==t)break;i?e[n]=a[f]:(u.push(t),a.push(o=(o=e[n],s)?gn(o)?o:[]:yn(o)?o:{}),e[n]=O(o,t,st,u,a))}else t!=r&&(e[n]=t)});return e}function M(e){var t=[];return pn(e,function(e){t.push(e)}),t}function _(e,t,n){var r=-1,s=
|
||||
e?e.length:0,o=i,n=(0>n?Ht(0,s+n):n)||0;return"number"==typeof s?o=-1<(A(e)?e.indexOf(t,n):W(e,t,n)):wn(e,function(e){if(++r>=n)return!(o=e===t)}),o}function D(e,t,r){var i=n,t=c(t,r);if(gn(e))for(var r=-1,s=e.length;++r<s&&(i=!!t(e[r],r,e)););else wn(e,function(e,n,r){return i=!!t(e,n,r)});return i}function P(e,t,n){var r=[],t=c(t,n);if(gn(e))for(var n=-1,i=e.length;++n<i;){var s=e[n];t(s,n,e)&&r.push(s)}else wn(e,function(e,n,i){t(e,n,i)&&r.push(e)});return r}function H(e,t,n){var r,t=c(t,n);return wn
|
||||
(e,function(e,n,s){if(t(e,n,s))return r=e,i}),r}function B(e,t,n){var r=-1,i=e?e.length:0,s=Array("number"==typeof i?i:0),t=c(t,n);if(gn(e))for(;++r<i;)s[r]=t(e[r],r,e);else wn(e,function(e,n,i){s[++r]=t(e,n,i)});return s}function j(e,t,n){var r=-Infinity,i=-1,s=e?e.length:0,o=r;if(t||!gn(e))t=!t&&A(e)?a:c(t,n),wn(e,function(e,n,i){n=t(e,n,i),n>r&&(r=n,o=e)});else for(;++i<s;)e[i]>o&&(o=e[i]);return o}function F(e,t){return B(e,t+"")}function I(e,t,n,r){var s=3>arguments.length;return t||(t=K),wn
|
||||
(e,function(e,o,u){n=s?(s=i,e):t.call(r,n,e,o,u)}),n}function q(e,t,n,r){var s=e,o=e?e.length:0,u=3>arguments.length;if("number"!=typeof o)var a=bn(e),o=a.length;else Gt&&A(e)&&(s=e.split(""));return t||(t=K),wn(e,function(e,f,l){f=a?a[--o]:--o,n=u?(u=i,s[f]):t.call(r,n,s[f],f,l)}),n}function R(e,t,n){var r,t=c(t,n);if(gn(e))for(var n=-1,i=e.length;++n<i&&!(r=t(e[n],n,e)););else wn(e,function(e,n,i){return!(r=t(e,n,i))});return!!r}function U(e,t,n){if(e){var i=e.length;return t==r||n?e[0]:g(e,0,Bt
|
||||
(Ht(0,t),i))}}function z(e,t){for(var n=-1,r=e?e.length:0,i=[];++n<r;){var s=e[n];gn(s)?kt.apply(i,t?s:z(s)):i.push(s)}return i}function W(e,t,n){var r=-1,i=e?e.length:0;if("number"==typeof n)r=(0>n?Ht(0,i+n):n||0)-1;else if(n)return r=V(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function X(e,t,n){return g(e,t==r||n?1:Ht(0,t))}function V(e,t,n,r){for(var i=0,s=e?e.length:i,n=n?c(n,r):K,t=n(t);i<s;)r=i+s>>>1,n(e[r])<t?i=r+1:s=r;return i}function $(e,t,n,r){var s=-1,o=e?e.length:0
|
||||
,u=[],a=u;"function"==typeof t&&(r=n,n=t,t=i);var f=!t&&74<o;if(f)var l={};n&&(a=[],n=c(n,r));for(;++s<o;){var r=e[s],h=n?n(r,s,e):r;f&&(a=Ct.call(l,h+"")?l[h]:l[h]=[]);if(t?!s||a[a.length-1]!==h:0>W(a,h))(n||f)&&a.push(h),u.push(r)}return u}function J(e,t){return en||Ot&&2<arguments.length?Ot.call.apply(Ot,arguments):l(e,t,g(arguments,2))}function K(e){return e}function Q(e){wn(x(e),function(t){var n=o[t]=e[t];o.prototype[t]=function(){var e=[this.__wrapped__];return kt.apply(e,arguments),e=n.apply
|
||||
(o,e),new o(e)}})}function G(){return this.__wrapped__}var n=!0,r=null,i=!1,Y="object"==typeof exports&&exports,Z="object"==typeof global&&global;Z.global===Z&&(e=Z);try{var et=e.document}catch(tt){}var nt=[],rt=new function(){},it=0,st=rt,ot=30,ut=e._,at=/[-?+=!~*%&^<>|{(\/]|\[\D|\b(?:delete|in|instanceof|new|typeof|void)\b/,ft=/&(?:amp|lt|gt|quot|#x27);/g,lt=/\b__p\+='';/g,ct=/\b(__p\+=)''\+/g,ht=/(__e\(.*?\)|\b__t\))\+'';/g,pt=/\w*$/,dt=/(?:__e|__t=)\(\s*(?![\d\s"']|this\.)/g,vt=RegExp("^"+(rt
|
||||
.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&").replace(/valueOf|for [^\]]+/g,".+?")+"$"),mt=/\$\{((?:(?=\\?)\\?[\s\S])*?)}/g,gt=/<%=([\s\S]+?)%>/g,yt=/($^)/,bt=/[&<>"']/g,wt=/['\n\r\t\u2028\u2029\\]/g,Et="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" "),St=Math.ceil,xt=nt.concat,Tt=Math.floor,Nt=vt.test(Nt=Object.getPrototypeOf)&&Nt,Ct=rt.hasOwnProperty,kt=nt.push,Lt=rt.propertyIsEnumerable,At=rt.toString,Ot=vt.test(Ot=g.bind)&&Ot,
|
||||
Mt=vt.test(Mt=Array.isArray)&&Mt,_t=e.isFinite,Dt=e.isNaN,Pt=vt.test(Pt=Object.keys)&&Pt,Ht=Math.max,Bt=Math.min,jt=Math.random,Ft="[object Arguments]",It="[object Array]",qt="[object Boolean]",Rt="[object Date]",Ut="[object Number]",zt="[object Object]",Wt="[object RegExp]",Xt="[object String]",Vt,$t,Jt=(Jt={0:1,length:1},nt.splice.call(Jt,0,1),Jt[0]),Kt=n;(function(){function e(){this.x=1}var t=[];e.prototype={valueOf:1,y:1};for(var n in new e)t.push(n);for(n in arguments)Kt=!n;Vt=!/valueOf/.test
|
||||
(t),$t="x"!=t[0]})(1);var Qt=!b(arguments),Gt="xx"!="x"[0]+Object("x")[0];try{var Yt=("[object Object]",At.call(et||0)==zt)}catch(Zt){}var en=Ot&&/\n|Opera/.test(Ot+At.call(e.opera)),tn=Pt&&/^.+$|true/.test(Pt+!!e.attachEvent),nn={"[object Function]":i};nn[Ft]=nn[It]=nn[qt]=nn[Rt]=nn[Ut]=nn[zt]=nn[Wt]=nn[Xt]=n;var rn={};rn[It]=Array,rn[qt]=Boolean,rn[Rt]=Date,rn[zt]=Object,rn[Ut]=Number,rn[Wt]=RegExp,rn[Xt]=String;var sn={"boolean":i,"function":n,object:n,number:i,string:i,"undefined":i},on={"\\"
|
||||
:"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};o.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:gt,variable:""};try{(/1/.test(function(){1})||s)()}catch(un){s=Function}var an={a:"o,v,g",k:"for(var a=1,b=typeof g=='number'?2:arguments.length;a<b;a++){if((l=arguments[a])){",g:"t[i]=l[i]",c:"}}"},fn={a:"d,c,w",k:"c=c&&typeof w=='undefined'?c:e(c,w)",b:"if(c(l[i],i,d)===false)return t",g:"if(c(l[i],i,d)===false)return t"},ln={b:r},cn=h(an
|
||||
);Qt&&(b=function(e){return e?Ct.call(e,"callee"):i});var hn=h(fn,ln,{l:i}),pn=h(fn,ln),dn={"&":"&","<":"<",">":">",'"':""","'":"'"},vn=T(dn),mn=h(an,{g:"if(t[i]==null)"+an.g}),gn=Mt||function(e){return At.call(e)==It};C(/x/)&&(C=function(e){return"[object Function]"==At.call(e)});var yn=Nt?function(e){if(!e||"object"!=typeof e)return i;var t=e.valueOf,n="function"==typeof t&&(n=Nt(t))&&Nt(n);return n?e==n||Nt(e)==n&&!b(e):w(e)}:w,bn=Pt?function(e){return"function"==typeof e&&
|
||||
Lt.call(e,"prototype")?E(e):k(e)?Pt(e):[]}:E,wn=h(fn);o.VERSION="0.10.0",o.assign=cn,o.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},o.bind=J,o.bindAll=function(e){for(var t=arguments,n=1<t.length?0:(t=x(e),-1),r=t.length;++n<r;){var i=t[n];e[i]=J(e[i],e)}return e},o.bindKey=function(e,t){return l(e,t,g(arguments,2))},o.chain=function(e){return new o(e)},o.clone=S,o.compact=function(e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r
|
||||
},o.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},o.contains=_,o.countBy=function(e,t,n){var r={},t=c(t,n);return wn(e,function(e,n,i){n=t(e,n,i),Ct.call(r,n)?r[n]++:r[n]=1}),r},o.debounce=function(e,t,n){function i(){a=r,n||(o=e.apply(u,s))}var s,o,u,a;return function(){var r=n&&!a;return s=arguments,u=this,clearTimeout(a),a=setTimeout(i,t),r&&(o=e.apply(u,s)),o}},o.defaults=mn,o.defer=function(e){var n=g(arguments,1
|
||||
);return setTimeout(function(){e.apply(t,n)},1)},o.delay=function(e,n){var r=g(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},o.difference=function(e){for(var t=-1,n=e?e.length:0,r=xt.apply(nt,arguments),r=u(r,n),i=[];++t<n;){var s=e[t];r(s)||i.push(s)}return i},o.escape=function(e){return e==r?"":(e+"").replace(bt,d)},o.every=D,o.filter=P,o.find=H,o.first=U,o.flatten=z,o.forEach=wn,o.forIn=hn,o.forOwn=pn,o.functions=x,o.groupBy=function(e,t,n){var r={},t=c(t,n);return wn(e,function(
|
||||
e,n,i){n=t(e,n,i),(Ct.call(r,n)?r[n]:r[n]=[]).push(e)}),r},o.has=function(e,t){return e?Ct.call(e,t):i},o.identity=K,o.indexOf=W,o.initial=function(e,t,n){if(!e)return[];var i=e.length;return g(e,0,Bt(Ht(0,i-(t==r||n?1:t||0)),i))},o.intersection=function(e){var t=arguments,n=t.length,r={},i=[];return wn(e,function(e){if(0>W(i,e)){for(var s=n;--s;)if(!(r[s]||(r[s]=u(t[s])))(e))return;i.push(e)}}),i},o.invert=T,o.invoke=function(e,t){var n=g(arguments,2),r="function"==typeof t,i=[];return wn(e,function(
|
||||
e){i.push((r?t:e[t]).apply(e,n))}),i},o.isArguments=b,o.isArray=gn,o.isBoolean=function(e){return e===n||e===i||At.call(e)==qt},o.isDate=function(e){return At.call(e)==Rt},o.isElement=function(e){return e?1===e.nodeType:i},o.isEmpty=function(e){var t=n;if(!e)return t;var r=At.call(e),s=e.length;return r==It||r==Xt||r==Ft||Qt&&b(e)||r==zt&&"number"==typeof s&&C(e.splice)?!s:(pn(e,function(){return t=i}),t)},o.isEqual=N,o.isFinite=function(e){return _t(e)&&!Dt(parseFloat(e))},o.isFunction=C,o.isNaN=
|
||||
function(e){return L(e)&&e!=+e},o.isNull=function(e){return e===r},o.isNumber=L,o.isObject=k,o.isPlainObject=yn,o.isRegExp=function(e){return At.call(e)==Wt},o.isString=A,o.isUndefined=function(e){return"undefined"==typeof e},o.keys=bn,o.last=function(e,t,n){if(e){var i=e.length;return t==r||n?e[i-1]:g(e,Ht(0,i-t))}},o.lastIndexOf=function(e,t,n){var r=e?e.length:0;for("number"==typeof n&&(r=(0>n?Ht(0,r+n):Bt(n,r-1))+1);r--;)if(e[r]===t)return r;return-1},o.map=B,o.max=j,o.memoize=function(e,t){var n=
|
||||
{};return function(){var r=t?t.apply(this,arguments):arguments[0];return Ct.call(n,r)?n[r]:n[r]=e.apply(this,arguments)}},o.merge=O,o.min=function(e,t,n){var r=Infinity,i=-1,s=e?e.length:0,o=r;if(t||!gn(e))t=!t&&A(e)?a:c(t,n),wn(e,function(e,n,i){n=t(e,n,i),n<r&&(r=n,o=e)});else for(;++i<s;)e[i]<o&&(o=e[i]);return o},o.mixin=Q,o.noConflict=function(){return e._=ut,this},o.object=function(e,t){for(var n=-1,r=e?e.length:0,i={};++n<r;){var s=e[n];t?i[s]=t[n]:i[s[0]]=s[1]}return i},o.omit=function(e,
|
||||
t,n){var r="function"==typeof t,i={};if(r)t=c(t,n);else var s=xt.apply(nt,arguments);return hn(e,function(e,n,o){if(r?!t(e,n,o):0>W(s,n,1))i[n]=e}),i},o.once=function(e){var t,s=i;return function(){return s?t:(s=n,t=e.apply(this,arguments),e=r,t)}},o.pairs=function(e){var t=[];return pn(e,function(e,n){t.push([n,e])}),t},o.partial=function(e){return l(e,g(arguments,1))},o.pick=function(e,t,n){var r={};if("function"!=typeof t)for(var i=0,s=xt.apply(nt,arguments),o=s.length;++i<o;){var u=s[i];u in
|
||||
e&&(r[u]=e[u])}else t=c(t,n),hn(e,function(e,n,i){t(e,n,i)&&(r[n]=e)});return r},o.pluck=F,o.random=function(e,t){return e==r&&t==r&&(t=1),e=+e||0,t==r&&(t=e,e=0),e+Tt(jt()*((+t||0)-e+1))},o.range=function(e,t,n){e=+e||0,n=+n||1,t==r&&(t=e,e=0);for(var i=-1,t=Ht(0,St((t-e)/n)),s=Array(t);++i<t;)s[i]=e,e+=n;return s},o.reduce=I,o.reduceRight=q,o.reject=function(e,t,n){return t=c(t,n),P(e,function(e,n,r){return!t(e,n,r)})},o.rest=X,o.result=function(e,t){var n=e?e[t]:r;return C(n)?e[t]():n},o.shuffle=
|
||||
function(e){var t=-1,n=Array(e?e.length:0);return wn(e,function(e){var r=Tt(jt()*(++t+1));n[t]=n[r],n[r]=e}),n},o.size=function(e){var t=e?e.length:0;return"number"==typeof t?t:bn(e).length},o.some=R,o.sortBy=function(e,t,n){var r=[],t=c(t,n);wn(e,function(e,n,i){r.push({a:t(e,n,i),b:n,c:e})}),e=r.length;for(r.sort(f);e--;)r[e]=r[e].c;return r},o.sortedIndex=V,o.tap=function(e,t){return t(e),e},o.template=function(e,t,n){e||(e=""),n||(n={});var r,i,u=o.templateSettings,a=0,f=n.interpolate||u.interpolate||
|
||||
yt,l="__p+='",c=n.variable||u.variable,h=c;e.replace(RegExp((n.escape||u.escape||yt).source+"|"+f.source+"|"+(f===gt?mt:yt).source+"|"+(n.evaluate||u.evaluate||yt).source+"|$","g"),function(t,n,i,s,o,u){return i||(i=s),l+=e.slice(a,u).replace(wt,p),n&&(l+="'+__e("+n+")+'"),o&&(l+="';"+o+";__p+='"),i&&(l+="'+((__t=("+i+"))==null?'':__t)+'"),r||(r=o||at.test(n||i)),a=u+t.length,t}),l+="';\n",h||(c="obj",r?l="with("+c+"){"+l+"}":(n=RegExp("(\\(\\s*)"+c+"\\."+c+"\\b","g"),l=l.replace(dt,"$&"+c+".").replace
|
||||
(n,"$1__d"))),l=(r?l.replace(lt,""):l).replace(ct,"$1").replace(ht,"$1;"),l="function("+c+"){"+(h?"":c+"||("+c+"={});")+"var __t,__p='',__e=_.escape"+(r?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":(h?"":",__d="+c+"."+c+"||"+c)+";")+l+"return __p}";try{i=s("_","return "+l)(o)}catch(d){throw d.source=l,d}return t?i(t):(i.source=l,i)},o.throttle=function(e,t){function n(){a=new Date,u=r,s=e.apply(o,i)}var i,s,o,u,a=0;return function(){var r=new Date,f=t-(r-a);return i=arguments
|
||||
,o=this,0>=f?(clearTimeout(u),a=r,s=e.apply(o,i)):u||(u=setTimeout(n,f)),s}},o.times=function(e,t,n){for(var e=+e||0,r=-1,i=Array(e);++r<e;)i[r]=t.call(n,r);return i},o.toArray=function(e){return"number"==typeof (e?e.length:0)?Gt&&A(e)?e.split(""):g(e):M(e)},o.unescape=function(e){return e==r?"":(e+"").replace(ft,y)},o.union=function(){return $(xt.apply(nt,arguments))},o.uniq=$,o.uniqueId=function(e){return(e==r?"":e+"")+ ++it},o.values=M,o.where=function(e,t){var n=bn(t);return P(e,function(e){for(
|
||||
var r=n.length;r--;){var i=e[n[r]]===t[n[r]];if(!i)break}return!!i})},o.without=function(e){for(var t=-1,n=e?e.length:0,r=u(arguments,1,20),i=[];++t<n;){var s=e[t];r(s)||i.push(s)}return i},o.wrap=function(e,t){return function(){var n=[e];return kt.apply(n,arguments),t.apply(this,n)}},o.zip=function(e){for(var t=-1,n=e?j(F(arguments,"length")):0,r=Array(n);++t<n;)r[t]=F(arguments,t);return r},o.all=D,o.any=R,o.collect=B,o.detect=H,o.drop=X,o.each=wn,o.extend=cn,o.foldl=I,o.foldr=q,o.head=U,o.include=
|
||||
_,o.inject=I,o.methods=x,o.select=P,o.tail=X,o.take=U,o.unique=$,Q(o),o.prototype.chain=function(){return this},o.prototype.toString=function(){return""+this.__wrapped__},o.prototype.value=G,o.prototype.valueOf=G,wn(["first","last"],function(e){var t=o[e];t&&(o.prototype[e]=function(e,n){var i=t(this.__wrapped__,e,n);return e==r||n?i:new o(i)})}),wn(P(x(o),function(e){return/^(?:contains|every|find|has|is[A-Z].+|reduce.*|some)$/.test(e)}),function(e){var t=o[e];o.prototype[e]=function(){var e=[this
|
||||
.__wrapped__];return kt.apply(e,arguments),t.apply(o,e)}}),wn("pop push reverse shift sort splice unshift".split(" "),function(e){var t=nt[e];o.prototype[e]=function(){var e=this.__wrapped__;return t.apply(e,arguments),Jt&&e.length===0&&delete e[0],this}}),wn(["concat","join","slice"],function(e){var t=nt[e];o.prototype[e]=function(){var e=t.apply(this.__wrapped__,arguments);return new o(e)}}),typeof define=="function"&&typeof define.amd=="object"&&define.amd?(e._=o,define(function(){return o})):
|
||||
Y?"object"==typeof module&&module&&module.exports==Y?(module.exports=o)._=o:Y._=o:e._=o})(this);
|
||||
;(function(e,t){function s(e){if(e&&"object"==typeof e&&e.__wrapped__)return e;if(!(this instanceof s))return new s(e);this.__wrapped__=e}function o(t,n){return e.eval("(function("+t+"){"+n+"})")}function u(e,t,n){t||(t=0);var r=e.length,i=r-t>=(n||it);if(i)for(var s={},n=t-1;++n<r;){var o=e[n]+"";(Tt.call(s,o)?s[o]:s[o]=[]).push(e[n])}return function(n){if(i){var r=n+"";return Tt.call(s,r)&&-1<W(s[r],n)}return-1<W(e,n,t)}}function a(e){return e.charCodeAt(0)}function f(e,t){var n=e.b,r=t.b,e=e.a,
|
||||
t=t.a;if(e!==t){if(e>t||"undefined"==typeof e)return 1;if(e<t||"undefined"==typeof t)return-1}return n<r?-1:1}function l(e,t,n){function i(){var r=arguments,a=o?this:t;return s||(e=t[u]),n.length&&(r=r.length?n.concat(g(r)):n),this instanceof i?(r=e.apply(this,r),k(r)?r:this):e.apply(a,r)}var s=C(e),o=!n,u=t;return o&&(n=t),s||(t=e),e&&e.prototype&&(m.prototype=e.prototype,i.prototype=new m,m.prototype=r),i}function c(e,t){return e?"function"!=typeof e?function(t){return t[e]}:"undefined"!=typeof
|
||||
t?function(n,r,i){return e.call(t,n,r,i)}:e:K}function h(){for(var e={b:"",c:"",e:Kt,f:Jt,g:"",h:Yt,i:en,j:bt,k:"",l:n},t,r=0;t=arguments[r];r++)for(var i in t)e[i]=t[i];t=e.a,e.d=/^[^,]+/.exec(t)[0],r="var i,l="+e.d+",t="+e.d+";if(!"+e.d+")return t;"+e.k+";",e.b?(r+="var m=l.length;i=-1;if(typeof m=='number'){",e.i&&(r+="if(k(l)){l=l.split('')}"),r+="while(++i<m){"+e.b+"}}else {"):e.h&&(r+="var m=l.length;i=-1;if(m&&j(l)){while(++i<m){i+='';"+e.g+"}}else {"),e.e||(r+="var u=typeof l=='function'&&s.call(l,'prototype');"
|
||||
);if(e.f&&e.l)r+="var q=-1,r=p[typeof l]?n(l):[],m=r.length;while(++q<m){i=r[q];",e.e||(r+="if(!(u&&i=='prototype')){"),r+=e.g+"",e.e||(r+="}");else{r+="for(i in l){";if(!e.e||e.l)r+="if(",e.e||(r+="!(u&&i=='prototype')"),!e.e&&e.l&&(r+="&&"),e.l&&(r+="h.call(l,i)"),r+="){";r+=e.g+";";if(!e.e||e.l)r+="}"}r+="}";if(e.e){r+="var f=l.constructor;";for(i=0;7>i;i++)r+="i='"+e.j[i]+"';if(","constructor"==e.j[i]&&(r+="!(f&&f.prototype===l)&&"),r+="h.call(l,i)){"+e.g+"}"}if(e.b||e.h)r+="}";return r+=e.c+";return t"
|
||||
,o("e,h,j,k,p,n,s","return function("+t+"){"+r+"}")(c,Tt,b,A,on,_t,Ct)}function p(e){return"\\"+un[e]}function d(e){return dn[e]}function v(e){return"function"!=typeof e.toString&&"string"==typeof (e+"")}function m(){}function g(e,t,n){t||(t=0),"undefined"==typeof n&&(n=e?e.length:0);for(var r=-1,n=n-t||0,i=Array(0>n?0:n);++r<n;)i[r]=e[t+r];return i}function y(e){return vn[e]}function b(e){return kt.call(e)==Bt}function w(e){var t=i;if(!e||"object"!=typeof e||b(e))return t;var n=e.constructor;return!
|
||||
C(n)&&(!tn||!v(e))||n instanceof n?Qt?(hn(e,function(e,n,r){return t=!Tt.call(r,n),i}),t===i):(hn(e,function(e,n){t=n}),t===i||Tt.call(e,t)):t}function E(e){var t=[];return pn(e,function(e,n){t.push(n)}),t}function S(e,t,n,s,o){if(e==r)return e;n&&(t=i);if(n=k(e)){var u=kt.call(e);if(!rn[u]||tn&&v(e))return e;var a=gn(e)}if(!n||!t)return n?a?g(e):cn({},e):e;n=sn[u];switch(u){case Ft:case It:return new n(+e);case qt:case zt:return new n(e);case Ut:return n(e.source,ct.exec(e))}s||(s=[]),o||(o=[]);
|
||||
for(u=s.length;u--;)if(s[u]==e)return o[u];var f=a?n(e.length):{};return s.push(e),o.push(f),(a?wn:pn)(e,function(e,n){f[n]=S(e,t,r,s,o)}),a&&(Tt.call(e,"index")&&(f.index=e.index),Tt.call(e,"input")&&(f.input=e.input)),f}function x(e){var t=[];return hn(e,function(e,n){C(e)&&t.push(n)}),t.sort()}function T(e){var t={};return pn(e,function(e,n){t[e]=n}),t}function N(e,t,s,o){if(e===t)return 0!==e||1/e==1/t;if(e==r||t==r)return e===t;var u=kt.call(e),a=kt.call(t);u==Bt&&(u=Rt),a==Bt&&(a=Rt);if(u!=
|
||||
a)return i;switch(u){case Ft:case It:return+e==+t;case qt:return e!=+e?t!=+t:0==e?1/e==1/t:e==+t;case Ut:case zt:return e==t+""}a=u==jt;if(!a){if(e.__wrapped__||t.__wrapped__)return N(e.__wrapped__||e,t.__wrapped__||t);if(u!=Rt||tn&&(v(e)||v(t)))return i;var u=e.constructor,f=t.constructor;if(u!=f&&(!C(u)||!(u instanceof u&&C(f)&&f instanceof f)))return i}s||(s=[]),o||(o=[]);for(u=s.length;u--;)if(s[u]==e)return o[u]==t;var l=n,c=0;s.push(e),o.push(t);if(a){c=e.length;if(l=c==t.length)for(;c--&&(
|
||||
l=N(e[c],t[c],s,o)););return l}return hn(e,function(e,n,r){if(Tt.call(r,n))return c++,l=Tt.call(t,n)&&N(e,t[n],s,o)}),l&&hn(t,function(e,t,n){if(Tt.call(n,t))return l=-1<--c}),l}function C(e){return"function"==typeof e}function k(e){return e?on[typeof e]:i}function L(e){return"number"==typeof e||kt.call(e)==qt}function A(e){return"string"==typeof e||kt.call(e)==zt}function O(e,t,n){var i=arguments,s=0,o=2,u=i[3],a=i[4];n!==rt&&(u=[],a=[],"number"!=typeof n&&(o=i.length));for(;++s<o;)pn(i[s],function(
|
||||
t,n){var i,s,o;if(t&&((s=gn(t))||yn(t))){for(var f=u.length;f--;)if(i=u[f]==t)break;i?e[n]=a[f]:(u.push(t),a.push(o=(o=e[n],s)?gn(o)?o:[]:yn(o)?o:{}),e[n]=O(o,t,rt,u,a))}else t!=r&&(e[n]=t)});return e}function M(e){var t=[];return pn(e,function(e){t.push(e)}),t}function _(e,t,n){var r=-1,s=e?e.length:0,o=i,n=(0>n?Dt(0,s+n):n)||0;return"number"==typeof s?o=-1<(A(e)?e.indexOf(t,n):W(e,t,n)):wn(e,function(e){if(++r>=n)return!(o=e===t)}),o}function D(e,t,r){var i=n,t=c(t,r);if(gn(e))for(var r=-1,s=e.
|
||||
length;++r<s&&(i=!!t(e[r],r,e)););else wn(e,function(e,n,r){return i=!!t(e,n,r)});return i}function P(e,t,n){var r=[],t=c(t,n);if(gn(e))for(var n=-1,i=e.length;++n<i;){var s=e[n];t(s,n,e)&&r.push(s)}else wn(e,function(e,n,i){t(e,n,i)&&r.push(e)});return r}function H(e,t,n){var r,t=c(t,n);return wn(e,function(e,n,s){if(t(e,n,s))return r=e,i}),r}function B(e,t,n){var r=-1,i=e?e.length:0,s=Array("number"==typeof i?i:0),t=c(t,n);if(gn(e))for(;++r<i;)s[r]=t(e[r],r,e);else wn(e,function(e,n,i){s[++r]=t
|
||||
(e,n,i)});return s}function j(e,t,n){var r=-Infinity,i=-1,s=e?e.length:0,o=r;if(t||!gn(e))t=!t&&A(e)?a:c(t,n),wn(e,function(e,n,i){n=t(e,n,i),n>r&&(r=n,o=e)});else for(;++i<s;)e[i]>o&&(o=e[i]);return o}function F(e,t){return B(e,t+"")}function I(e,t,n,r){var s=3>arguments.length;return t||(t=K),wn(e,function(e,o,u){n=s?(s=i,e):t.call(r,n,e,o,u)}),n}function q(e,t,n,r){var s=e,o=e?e.length:0,u=3>arguments.length;if("number"!=typeof o)var a=bn(e),o=a.length;else en&&A(e)&&(s=e.split(""));return t||
|
||||
(t=K),wn(e,function(e,f,l){f=a?a[--o]:--o,n=u?(u=i,s[f]):t.call(r,n,s[f],f,l)}),n}function R(e,t,n){var r,t=c(t,n);if(gn(e))for(var n=-1,i=e.length;++n<i&&!(r=t(e[n],n,e)););else wn(e,function(e,n,i){return!(r=t(e,n,i))});return!!r}function U(e,t,n){if(e){var i=e.length;return t==r||n?e[0]:g(e,0,Pt(Dt(0,t),i))}}function z(e,t){for(var n=-1,r=e?e.length:0,i=[];++n<r;){var s=e[n];gn(s)?Nt.apply(i,t?s:z(s)):i.push(s)}return i}function W(e,t,n){var r=-1,i=e?e.length:0;if("number"==typeof n)r=(0>n?Dt(0
|
||||
,i+n):n||0)-1;else if(n)return r=V(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function X(e,t,n){return g(e,t==r||n?1:Dt(0,t))}function V(e,t,n,r){for(var i=0,s=e?e.length:i,n=n?c(n,r):K,t=n(t);i<s;)r=i+s>>>1,n(e[r])<t?i=r+1:s=r;return i}function $(e,t,n,r){var s=-1,o=e?e.length:0,u=[],a=u;"function"==typeof t&&(r=n,n=t,t=i);var f=!t&&74<o;if(f)var l={};n&&(a=[],n=c(n,r));for(;++s<o;){var r=e[s],h=n?n(r,s,e):r;f&&(a=Tt.call(l,h+"")?l[h]:l[h]=[]);if(t?!s||a[a.length-1]!==h:0>W(a,h
|
||||
))(n||f)&&a.push(h),u.push(r)}return u}function J(e,t){return $t||Lt&&2<arguments.length?Lt.call.apply(Lt,arguments):l(e,t,g(arguments,2))}function K(e){return e}function Q(e){wn(x(e),function(t){var n=s[t]=e[t];s.prototype[t]=function(){var e=[this.__wrapped__];return Nt.apply(e,arguments),e=n.apply(s,e),new s(e)}})}function G(){return this.__wrapped__}var n=!0,r=null,i=!1,Y="object"==typeof exports&&exports,Z="object"==typeof global&&global;Z.global===Z&&(e=Z);var et=[],tt=new function(){},nt=0
|
||||
,rt=tt,it=30,st=e._,ot=/[-?+=!~*%&^<>|{(\/]|\[\D|\b(?:delete|in|instanceof|new|typeof|void)\b/,ut=/&(?:amp|lt|gt|quot|#x27);/g,at=/\b__p\+='';/g,ft=/\b(__p\+=)''\+/g,lt=/(__e\(.*?\)|\b__t\))\+'';/g,ct=/\w*$/,ht=/(?:__e|__t=)\(\s*(?![\d\s"']|this\.)/g,pt=RegExp("^"+(tt.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&").replace(/valueOf|for [^\]]+/g,".+?")+"$"),dt=/\$\{((?:(?=\\?)\\?[\s\S])*?)}/g,vt=/<%=([\s\S]+?)%>/g,mt=/($^)/,gt=/[&<>"']/g,yt=/['\n\r\t\u2028\u2029\\]/g,bt="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf"
|
||||
.split(" "),wt=Math.ceil,Et=et.concat,St=Math.floor,xt=pt.test(xt=Object.getPrototypeOf)&&xt,Tt=tt.hasOwnProperty,Nt=et.push,Ct=tt.propertyIsEnumerable,kt=tt.toString,Lt=pt.test(Lt=g.bind)&&Lt,At=pt.test(At=Array.isArray)&&At,Ot=e.isFinite,Mt=e.isNaN,_t=pt.test(_t=Object.keys)&&_t,Dt=Math.max,Pt=Math.min,Ht=Math.random,Bt="[object Arguments]",jt="[object Array]",Ft="[object Boolean]",It="[object Date]",qt="[object Number]",Rt="[object Object]",Ut="[object RegExp]",zt="[object String]",Wt=!/1/.test
|
||||
(Function("1")),Xt=!!e.attachEvent,Vt=Lt&&!/\n|true/.test(Lt+Xt),$t=Lt&&!Vt,Jt=_t&&(Xt||Vt),Kt,Qt,Gt=(Gt={0:1,length:1},et.splice.call(Gt,0,1),Gt[0]),Yt=n;(function(){function e(){this.x=1}var t=[];e.prototype={valueOf:1,y:1};for(var n in new e)t.push(n);for(n in arguments)Yt=!n;Kt=!/valueOf/.test(t),Qt="x"!=t[0]})(1);var Zt=!b(arguments),en="xx"!="x"[0]+Object("x")[0];try{var tn=("[object Object]",kt.call(document)==Rt)}catch(nn){}var rn={"[object Function]":i};rn[Bt]=rn[jt]=rn[Ft]=rn[It]=rn[qt]=
|
||||
rn[Rt]=rn[Ut]=rn[zt]=n;var sn={};sn[jt]=Array,sn[Ft]=Boolean,sn[It]=Date,sn[Rt]=Object,sn[qt]=Number,sn[Ut]=RegExp,sn[zt]=String;var on={"boolean":i,"function":n,object:n,number:i,string:i,"undefined":i},un={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};s.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:vt,variable:""};if(Xt||Vt||!Wt)o=Function;var an={a:"o,v,g",k:"for(var a=1,b=typeof g=='number'?2:arguments.length;a<b;a++){if((l=arguments[a])){"
|
||||
,g:"t[i]=l[i]",c:"}}"},fn={a:"d,c,w",k:"c=c&&typeof w=='undefined'?c:e(c,w)",b:"if(c(l[i],i,d)===false)return t",g:"if(c(l[i],i,d)===false)return t"},ln={b:r},cn=h(an);Zt&&(b=function(e){return e?Tt.call(e,"callee"):i});var hn=h(fn,ln,{l:i}),pn=h(fn,ln),dn={"&":"&","<":"<",">":">",'"':""","'":"'"},vn=T(dn),mn=h(an,{g:"if(t[i]==null)"+an.g}),gn=At||function(e){return kt.call(e)==jt};C(/x/)&&(C=function(e){return"[object Function]"==kt.call(e)});var yn=xt?function(e){if(!e||"object"!=typeof
|
||||
e)return i;var t=e.valueOf,n="function"==typeof t&&(n=xt(t))&&xt(n);return n?e==n||xt(e)==n&&!b(e):w(e)}:w,bn=_t?function(e){return"function"==typeof e&&Ct.call(e,"prototype")?E(e):k(e)?_t(e):[]}:E,wn=h(fn);s.VERSION="1.0.0-rc.1",s.assign=cn,s.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},s.bind=J,s.bindAll=function(e){for(var t=arguments,n=1<t.length?0:(t=x(e),-1),r=t.length;++n<r;){var i=t[n];e[i]=J(e[i],e)}return e},s.bindKey=function(e,t){return l(e,t
|
||||
,g(arguments,2))},s.chain=function(e){return new s(e)},s.clone=S,s.compact=function(e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r},s.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},s.contains=_,s.countBy=function(e,t,n){var r={},t=c(t,n);return wn(e,function(e,n,i){n=t(e,n,i),Tt.call(r,n)?r[n]++:r[n]=1}),r},s.debounce=function(e,t,n){function i(){a=r,n||(o=e.apply(u,s))}var s,o,u,a;return function(
|
||||
){var r=n&&!a;return s=arguments,u=this,clearTimeout(a),a=setTimeout(i,t),r&&(o=e.apply(u,s)),o}},s.defaults=mn,s.defer=function(e){var n=g(arguments,1);return setTimeout(function(){e.apply(t,n)},1)},s.delay=function(e,n){var r=g(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},s.difference=function(e){for(var t=-1,n=e?e.length:0,r=Et.apply(et,arguments),r=u(r,n),i=[];++t<n;){var s=e[t];r(s)||i.push(s)}return i},s.escape=function(e){return e==r?"":(e+"").replace(gt,d)},s.every=D,s.filter=
|
||||
P,s.find=H,s.first=U,s.flatten=z,s.forEach=wn,s.forIn=hn,s.forOwn=pn,s.functions=x,s.groupBy=function(e,t,n){var r={},t=c(t,n);return wn(e,function(e,n,i){n=t(e,n,i),(Tt.call(r,n)?r[n]:r[n]=[]).push(e)}),r},s.has=function(e,t){return e?Tt.call(e,t):i},s.identity=K,s.indexOf=W,s.initial=function(e,t,n){if(!e)return[];var i=e.length;return g(e,0,Pt(Dt(0,i-(t==r||n?1:t||0)),i))},s.intersection=function(e){var t=arguments,n=t.length,r={},i=[];return wn(e,function(e){if(0>W(i,e)){for(var s=n;--s;)if(!
|
||||
(r[s]||(r[s]=u(t[s])))(e))return;i.push(e)}}),i},s.invert=T,s.invoke=function(e,t){var n=g(arguments,2),r="function"==typeof t,i=[];return wn(e,function(e){i.push((r?t:e[t]).apply(e,n))}),i},s.isArguments=b,s.isArray=gn,s.isBoolean=function(e){return e===n||e===i||kt.call(e)==Ft},s.isDate=function(e){return kt.call(e)==It},s.isElement=function(e){return e?1===e.nodeType:i},s.isEmpty=function(e){var t=n;if(!e)return t;var r=kt.call(e),s=e.length;return r==jt||r==zt||r==Bt||Zt&&b(e)||r==Rt&&"number"==typeof
|
||||
s&&C(e.splice)?!s:(pn(e,function(){return t=i}),t)},s.isEqual=N,s.isFinite=function(e){return Ot(e)&&!Mt(parseFloat(e))},s.isFunction=C,s.isNaN=function(e){return L(e)&&e!=+e},s.isNull=function(e){return e===r},s.isNumber=L,s.isObject=k,s.isPlainObject=yn,s.isRegExp=function(e){return kt.call(e)==Ut},s.isString=A,s.isUndefined=function(e){return"undefined"==typeof e},s.keys=bn,s.last=function(e,t,n){if(e){var i=e.length;return t==r||n?e[i-1]:g(e,Dt(0,i-t))}},s.lastIndexOf=function(e,t,n){var r=e?
|
||||
e.length:0;for("number"==typeof n&&(r=(0>n?Dt(0,r+n):Pt(n,r-1))+1);r--;)if(e[r]===t)return r;return-1},s.map=B,s.max=j,s.memoize=function(e,t){var n={};return function(){var r=t?t.apply(this,arguments):arguments[0];return Tt.call(n,r)?n[r]:n[r]=e.apply(this,arguments)}},s.merge=O,s.min=function(e,t,n){var r=Infinity,i=-1,s=e?e.length:0,o=r;if(t||!gn(e))t=!t&&A(e)?a:c(t,n),wn(e,function(e,n,i){n=t(e,n,i),n<r&&(r=n,o=e)});else for(;++i<s;)e[i]<o&&(o=e[i]);return o},s.mixin=Q,s.noConflict=function()
|
||||
{return e._=st,this},s.object=function(e,t){for(var n=-1,r=e?e.length:0,i={};++n<r;){var s=e[n];t?i[s]=t[n]:i[s[0]]=s[1]}return i},s.omit=function(e,t,n){var r="function"==typeof t,i={};if(r)t=c(t,n);else var s=Et.apply(et,arguments);return hn(e,function(e,n,o){if(r?!t(e,n,o):0>W(s,n,1))i[n]=e}),i},s.once=function(e){var t,s=i;return function(){return s?t:(s=n,t=e.apply(this,arguments),e=r,t)}},s.pairs=function(e){var t=[];return pn(e,function(e,n){t.push([n,e])}),t},s.partial=function(e){return l
|
||||
(e,g(arguments,1))},s.pick=function(e,t,n){var r={};if("function"!=typeof t)for(var i=0,s=Et.apply(et,arguments),o=s.length;++i<o;){var u=s[i];u in e&&(r[u]=e[u])}else t=c(t,n),hn(e,function(e,n,i){t(e,n,i)&&(r[n]=e)});return r},s.pluck=F,s.random=function(e,t){return e==r&&t==r&&(t=1),e=+e||0,t==r&&(t=e,e=0),e+St(Ht()*((+t||0)-e+1))},s.range=function(e,t,n){e=+e||0,n=+n||1,t==r&&(t=e,e=0);for(var i=-1,t=Dt(0,wt((t-e)/n)),s=Array(t);++i<t;)s[i]=e,e+=n;return s},s.reduce=I,s.reduceRight=q,s.reject=
|
||||
function(e,t,n){return t=c(t,n),P(e,function(e,n,r){return!t(e,n,r)})},s.rest=X,s.result=function(e,t){var n=e?e[t]:r;return C(n)?e[t]():n},s.shuffle=function(e){var t=-1,n=Array(e?e.length:0);return wn(e,function(e){var r=St(Ht()*(++t+1));n[t]=n[r],n[r]=e}),n},s.size=function(e){var t=e?e.length:0;return"number"==typeof t?t:bn(e).length},s.some=R,s.sortBy=function(e,t,n){var r=[],t=c(t,n);wn(e,function(e,n,i){r.push({a:t(e,n,i),b:n,c:e})}),e=r.length;for(r.sort(f);e--;)r[e]=r[e].c;return r},s.sortedIndex=
|
||||
V,s.tap=function(e,t){return t(e),e},s.template=function(e,t,n){e||(e=""),n||(n={});var r,i,u=s.templateSettings,a=0,f=n.interpolate||u.interpolate||mt,l="__p+='",c=n.variable||u.variable,h=c;e.replace(RegExp((n.escape||u.escape||mt).source+"|"+f.source+"|"+(f===vt?dt:mt).source+"|"+(n.evaluate||u.evaluate||mt).source+"|$","g"),function(t,n,i,s,o,u){return i||(i=s),l+=e.slice(a,u).replace(yt,p),n&&(l+="'+__e("+n+")+'"),o&&(l+="';"+o+";__p+='"),i&&(l+="'+((__t=("+i+"))==null?'':__t)+'"),r||(r=o||ot
|
||||
.test(n||i)),a=u+t.length,t}),l+="';\n",h||(c="obj",r?l="with("+c+"){"+l+"}":(n=RegExp("(\\(\\s*)"+c+"\\."+c+"\\b","g"),l=l.replace(ht,"$&"+c+".").replace(n,"$1__d"))),l=(r?l.replace(at,""):l).replace(ft,"$1").replace(lt,"$1;"),l="function("+c+"){"+(h?"":c+"||("+c+"={});")+"var __t,__p='',__e=_.escape"+(r?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":(h?"":",__d="+c+"."+c+"||"+c)+";")+l+"return __p}";try{i=o("_","return "+l)(s)}catch(d){throw d.source=l,d}return t?i(t)
|
||||
:(i.source=l,i)},s.throttle=function(e,t){function n(){a=new Date,u=r,s=e.apply(o,i)}var i,s,o,u,a=0;return function(){var r=new Date,f=t-(r-a);return i=arguments,o=this,0>=f?(clearTimeout(u),a=r,s=e.apply(o,i)):u||(u=setTimeout(n,f)),s}},s.times=function(e,t,n){for(var e=+e||0,r=-1,i=Array(e);++r<e;)i[r]=t.call(n,r);return i},s.toArray=function(e){return"number"==typeof (e?e.length:0)?en&&A(e)?e.split(""):g(e):M(e)},s.unescape=function(e){return e==r?"":(e+"").replace(ut,y)},s.union=function(){return $
|
||||
(Et.apply(et,arguments))},s.uniq=$,s.uniqueId=function(e){return(e==r?"":e+"")+ ++nt},s.values=M,s.where=function(e,t){var n=bn(t);return P(e,function(e){for(var r=n.length;r--;){var i=e[n[r]]===t[n[r]];if(!i)break}return!!i})},s.without=function(e){for(var t=-1,n=e?e.length:0,r=u(arguments,1,20),i=[];++t<n;){var s=e[t];r(s)||i.push(s)}return i},s.wrap=function(e,t){return function(){var n=[e];return Nt.apply(n,arguments),t.apply(this,n)}},s.zip=function(e){for(var t=-1,n=e?j(F(arguments,"length"
|
||||
)):0,r=Array(n);++t<n;)r[t]=F(arguments,t);return r},s.all=D,s.any=R,s.collect=B,s.detect=H,s.drop=X,s.each=wn,s.extend=cn,s.foldl=I,s.foldr=q,s.head=U,s.include=_,s.inject=I,s.methods=x,s.select=P,s.tail=X,s.take=U,s.unique=$,Q(s),s.prototype.chain=function(){return this},s.prototype.toString=function(){return""+this.__wrapped__},s.prototype.value=G,s.prototype.valueOf=G,wn(["first","last"],function(e){var t=s[e];t&&(s.prototype[e]=function(e,n){var i=t(this.__wrapped__,e,n);return e==r||n?i:new
|
||||
s(i)})}),wn(P(x(s),function(e){return/^(?:bind|contains|every|find|has|is[A-Z].+|reduce.*|some)$/.test(e)}),function(e){var t=s[e];s.prototype[e]=function(){var e=[this.__wrapped__];return Nt.apply(e,arguments),t.apply(s,e)}}),wn("pop push reverse shift sort splice unshift".split(" "),function(e){var t=et[e];s.prototype[e]=function(){var e=this.__wrapped__;return t.apply(e,arguments),Gt&&e.length===0&&delete e[0],this}}),wn(["concat","join","slice"],function(e){var t=et[e];s.prototype[e]=function(
|
||||
){var e=t.apply(this.__wrapped__,arguments);return new s(e)}}),typeof define=="function"&&typeof define.amd=="object"&&define.amd?(e._=s,define(function(){return s})):Y?"object"==typeof module&&module&&module.exports==Y?(module.exports=s)._=s:Y._=s:e._=s})(this);
|
||||
33
lodash.underscore.js
Normal file
33
lodash.underscore.js
Normal file
@@ -0,0 +1,33 @@
|
||||
/*!
|
||||
Lo-Dash 1.0.0-rc.1 (Custom Build) lodash.com/license
|
||||
Build: `lodash underscore -m -o ./lodash.underscore.js`
|
||||
Underscore.js 1.4.2 underscorejs.org/LICENSE
|
||||
*/
|
||||
;(function(e,t){function n(e){if(e&&"object"==typeof e&&e.__wrapped__)return e;if(!(this instanceof n))return new n(e);this.__wrapped__=e}function r(e,t){var n=e.b,r=t.b,e=e.a,t=t.a;if(e!==t){if(e>t||"undefined"==typeof e)return 1;if(e<t||"undefined"==typeof t)return-1}return n<r?-1:1}function i(e,t,n){function r(){var i=arguments,s=t;return n.length&&(i=i.length?n.concat(f(i)):n),this instanceof r?(i=e.apply(this,i),y(i)?i:this):e.apply(s,i)}return e&&e.prototype&&(a.prototype=e.prototype,r.prototype=new
|
||||
a,a.prototype=null),r}function s(e,t){return e?"function"!=typeof e?function(t){return t[e]}:"undefined"!=typeof t?function(n,r,i){return e.call(t,n,r,i)}:e:I}function o(e){return"\\"+Et[e]}function u(e){return Tt[e]}function a(){}function f(e,t,n){t||(t=0),"undefined"==typeof n&&(n=e?e.length:0);for(var r=-1,n=n-t||0,i=Array(0>n?0:n);++r<n;)i[r]=e[t+r];return i}function l(e){return Nt[e]}function c(e){if(!e)return e;for(var t=1,n=arguments.length;t<n;t++){var r=arguments[t];if(r)for(var i in r)e
|
||||
[i]=r[i]}return e}function h(e){var t=[];return xt(e,function(e,n){t.push(n)}),t}function p(e){if(!e)return e;for(var t=1,n=arguments.length;t<n;t++){var r=arguments[t];if(r)for(var i in r)null==e[i]&&(e[i]=r[i])}return e}function d(e){var t=[];return St(e,function(e,n){g(e)&&t.push(n)}),t.sort()}function v(e){var t={};return xt(e,function(e,n){t[e]=n}),t}function m(e,t,n,r){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return e===t;var i=rt.call(e),s=rt.call(t);if(i!=s)return!1;switch(i){case ht
|
||||
:case pt:return+e==+t;case dt:return e!=+e?t!=+t:0==e?1/e==1/t:e==+t;case mt:case gt:return e==t+""}s=i==ct;if(!s){if(e.__wrapped__||t.__wrapped__)return m(e.__wrapped__||e,t.__wrapped__||t);if(i!=vt)return!1;var i=e.constructor,o=t.constructor;if(i!=o&&(!g(i)||!(i instanceof i&&g(o)&&o instanceof o)))return!1}n||(n=[]),r||(r=[]);for(i=n.length;i--;)if(n[i]==e)return r[i]==t;var u=!0,a=0;n.push(e),r.push(t);if(s){a=e.length;if(u=a==t.length)for(;a--&&(u=m(e[a],t[a],n,r)););return u}return St(e,function(
|
||||
e,i,s){if(tt.call(s,i))return a++,!(u=tt.call(t,i)&&m(e,t[i],n,r))&&X}),u&&St(t,function(e,t,n){if(tt.call(n,t))return!(u=-1<--a)&&X}),u}function g(e){return"function"==typeof e}function y(e){return e?wt[typeof e]:!1}function b(e){return"number"==typeof e||rt.call(e)==dt}function w(e){return"string"==typeof e||rt.call(e)==gt}function E(e){var t=[];return xt(e,function(e){t.push(e)}),t}function S(e,t){var n=!1;return"number"==typeof (e?e.length:0)?n=-1<P(e,t):Lt(e,function(e){return(n=e===t)&&X}),
|
||||
n}function x(e,t,n){var r=!0,t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i&&(r=!!t(e[n],n,e)););else Lt(e,function(e,n,i){return!(r=!!t(e,n,i))&&X});return r}function T(e,t,n){var r=[],t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i;){var o=e[n];t(o,n,e)&&r.push(o)}else Lt(e,function(e,n,i){t(e,n,i)&&r.push(e)});return r}function N(e,t,n){var r,t=s(t,n);return Lt(e,function(e,n,i){if(t(e,n,i))return r=e,X}),r}function C(e,t,n){var r=-1,i=e?e.length:0,o=Array("number"==typeof i?i:0),t=s(t,n);if(
|
||||
Ct(e))for(;++r<i;)o[r]=t(e[r],r,e);else Lt(e,function(e,n,i){o[++r]=t(e,n,i)});return o}function k(e,t,n){var r=-Infinity,i=-1,o=e?e.length:0,u=r;if(t||!Ct(e))t=s(t,n),Lt(e,function(e,n,i){n=t(e,n,i),n>r&&(r=n,u=e)});else for(;++i<o;)e[i]>u&&(u=e[i]);return u}function L(e,t){return C(e,t+"")}function A(e,t,n,r){var i=3>arguments.length;return t||(t=I),Lt(e,function(e,s,o){n=i?(i=!1,e):t.call(r,n,e,s,o)}),n}function O(e,t,n,r){var i=e?e.length:0,s=3>arguments.length;if("number"!=typeof i)var o=kt(
|
||||
e),i=o.length;return t||(t=I),Lt(e,function(u,a,f){a=o?o[--i]:--i,n=s?(s=!1,e[a]):t.call(r,n,e[a],a,f)}),n}function M(e,t,n){var r,t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i&&!(r=t(e[n],n,e)););else Lt(e,function(e,n,i){return(r=t(e,n,i))&&X});return!!r}function _(e,t,n){if(e){var r=e.length;return null==t||n?e[0]:f(e,0,ft(at(0,t),r))}}function D(e,t){for(var n=-1,r=e?e.length:0,i=[];++n<r;){var s=e[n];Ct(s)?nt.apply(i,t?s:D(s)):i.push(s)}return i}function P(e,t,n){var r=-1,i=e?e.length:0;if("number"==typeof
|
||||
n)r=(0>n?at(0,i+n):n||0)-1;else if(n)return r=B(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function H(e,t,n){return f(e,null==t||n?1:at(0,t))}function B(e,t,n,r){for(var i=0,o=e?e.length:i,n=n?s(n,r):I,t=n(t);i<o;)r=i+o>>>1,n(e[r])<t?i=r+1:o=r;return i}function j(e,t,n,r){var i=-1,o=e?e.length:0,u=[],a=u;n&&(a=[],n=s(n,r));for(;++i<o;){var r=e[i],f=n?n(r,i,e):r;if(t?!i||a[a.length-1]!==f:0>P(a,f))n&&a.push(f),u.push(r)}return u}function F(e,t){return yt||it&&2<arguments.length?it
|
||||
.call.apply(it,arguments):i(e,t,f(arguments,2))}function I(e){return e}function q(e){Lt(d(e),function(t){var r=n[t]=e[t];n.prototype[t]=function(){var e=[this.__wrapped__];return nt.apply(e,arguments),e=r.apply(n,e),this.__chain__&&(e=new n(e),e.__chain__=!0),e}})}var R="object"==typeof exports&&exports,U="object"==typeof global&&global;U.global===U&&(e=U);var z=[],U=new function(){},W=0,X=U,V=e._,$=/&(?:amp|lt|gt|quot|#x27);/g,J=RegExp("^"+(U.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&"
|
||||
).replace(/valueOf|for [^\]]+/g,".+?")+"$"),K=/($^)/,Q=/[&<>"']/g,G=/['\n\r\t\u2028\u2029\\]/g,Y=Math.ceil,Z=z.concat,et=Math.floor,tt=U.hasOwnProperty,nt=z.push,rt=U.toString,it=J.test(it=f.bind)&&it,st=J.test(st=Array.isArray)&&st,ot=e.isFinite,ut=J.test(ut=Object.keys)&&ut,at=Math.max,ft=Math.min,lt=Math.random,ct="[object Array]",ht="[object Boolean]",pt="[object Date]",dt="[object Number]",vt="[object Object]",mt="[object RegExp]",gt="[object String]",U=!!e.attachEvent,U=it&&!/\n|true/.test(
|
||||
it+U),yt=it&&!U,bt=(bt={0:1,length:1},z.splice.call(bt,0,1),bt[0]),wt={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,"undefined":!1},Et={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};n.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,variable:""},n.isArguments=function(e){return"[object Arguments]"==rt.call(e)},n.isArguments(arguments)||(n.isArguments=function(e){return e?tt.call(e,"callee"):!1});var St=
|
||||
function(e,t){var n;if(!e)return e;t||(t=I);for(n in e)if(t(e[n],n,e)===X)break;return e},xt=function(e,t){var n;if(!e)return e;t||(t=I);for(n in e)if(tt.call(e,n)&&t(e[n],n,e)===X)break;return e},Tt={"&":"&","<":"<",">":">",'"':""","'":"'"},Nt=v(Tt),Ct=st||function(e){return rt.call(e)==ct};g(/x/)&&(g=function(e){return"[object Function]"==rt.call(e)});var kt=ut?function(e){return y(e)?ut(e):[]}:h,Lt=function(e,t,n){if(!e)return e;var t=t&&"undefined"==typeof n?t:s(t,n),r=e.length
|
||||
,n=-1;if("number"==typeof r){for(;++n<r;)if(t(e[n],n,e)===X)return e}else for(n in e)if(tt.call(e,n)&&t(e[n],n,e)===X)return e};n.VERSION="1.0.0-rc.1",n.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},n.bind=F,n.bindAll=function(e){for(var t=arguments,n=1<t.length?0:(t=d(e),-1),r=t.length;++n<r;){var i=t[n];e[i]=F(e[i],e)}return e},n.chain=function(e){return e=new n(e),e.__chain__=!0,e},n.clone=function(e){return e&&wt[typeof e]?Ct(e)?f(e):c({},e):e},n.compact=
|
||||
function(e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r},n.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},n.contains=S,n.countBy=function(e,t,n){var r={},t=s(t,n);return Lt(e,function(e,n,i){n=t(e,n,i),tt.call(r,n)?r[n]++:r[n]=1}),r},n.debounce=function(e,t,n){function r(){u=null,n||(s=e.apply(o,i))}var i,s,o,u;return function(){var a=n&&!u;return i=arguments,o=this,clearTimeout(u),u=setTimeout
|
||||
(r,t),a&&(s=e.apply(o,i)),s}},n.defaults=p,n.defer=function(e){var n=f(arguments,1);return setTimeout(function(){e.apply(t,n)},1)},n.delay=function(e,n){var r=f(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},n.difference=function(e){for(var t=-1,n=e.length,r=Z.apply(z,arguments),i=[];++t<n;){var s=e[t];0>P(r,s,n)&&i.push(s)}return i},n.escape=function(e){return null==e?"":(e+"").replace(Q,u)},n.every=x,n.filter=T,n.find=N,n.first=_,n.flatten=D,n.forEach=Lt,n.functions=d,n.groupBy=function(
|
||||
e,t,n){var r={},t=s(t,n);return Lt(e,function(e,n,i){n=t(e,n,i),(tt.call(r,n)?r[n]:r[n]=[]).push(e)}),r},n.has=function(e,t){return e?tt.call(e,t):!1},n.identity=I,n.indexOf=P,n.initial=function(e,t,n){if(!e)return[];var r=e.length;return f(e,0,ft(at(0,r-(null==t||n?1:t||0)),r))},n.intersection=function(e){var t=arguments,n=t.length,r=[];return Lt(e,function(e){if(0>P(r,e)){for(var i=n;--i;)if(0>P(t[i],e))return;r.push(e)}}),r},n.invert=v,n.invoke=function(e,t){var n=f(arguments,2),r="function"==typeof
|
||||
t,i=[];return Lt(e,function(e){i.push((r?t:e[t]).apply(e,n))}),i},n.isArray=Ct,n.isBoolean=function(e){return!0===e||!1===e||rt.call(e)==ht},n.isDate=function(e){return rt.call(e)==pt},n.isElement=function(e){return e?1===e.nodeType:!1},n.isEmpty=function(e){if(!e)return!0;if(Ct(e)||w(e))return!e.length;for(var t in e)if(tt.call(e,t))return!1;return!0},n.isEqual=m,n.isFinite=function(e){return ot(e)&&rt.call(e)==dt},n.isFunction=g,n.isNaN=function(e){return b(e)&&e!=+e},n.isNull=function(e){return null===
|
||||
e},n.isNumber=b,n.isObject=y,n.isRegExp=function(e){return rt.call(e)==mt},n.isString=w,n.isUndefined=function(e){return"undefined"==typeof e},n.keys=kt,n.last=function(e,t,n){if(e){var r=e.length;return null==t||n?e[r-1]:f(e,at(0,r-t))}},n.lastIndexOf=function(e,t,n){var r=e?e.length:0;for("number"==typeof n&&(r=(0>n?at(0,r+n):ft(n,r-1))+1);r--;)if(e[r]===t)return r;return-1},n.map=C,n.max=k,n.memoize=function(e,t){var n={};return function(){var r=t?t.apply(this,arguments):arguments[0];return tt
|
||||
.call(n,r)?n[r]:n[r]=e.apply(this,arguments)}},n.min=function(e,t,n){var r=Infinity,i=-1,o=e?e.length:0,u=r;if(t||!Ct(e))t=s(t,n),Lt(e,function(e,n,i){n=t(e,n,i),n<r&&(r=n,u=e)});else for(;++i<o;)e[i]<u&&(u=e[i]);return u},n.mixin=q,n.noConflict=function(){return e._=V,this},n.object=function(e,t){for(var n=-1,r=e?e.length:0,i={};++n<r;){var s=e[n];t?i[s]=t[n]:i[s[0]]=s[1]}return i},n.omit=function(e){var t=Z.apply(z,arguments),n={};return St(e,function(e,r){0>P(t,r,1)&&(n[r]=e)}),n},n.once=function(
|
||||
e){var t,n=!1;return function(){return n?t:(n=!0,t=e.apply(this,arguments),e=null,t)}},n.pairs=function(e){var t=[];return xt(e,function(e,n){t.push([n,e])}),t},n.pick=function(e){for(var t=0,n=Z.apply(z,arguments),r=n.length,i={};++t<r;){var s=n[t];s in e&&(i[s]=e[s])}return i},n.pluck=L,n.random=function(e,t){return null==e&&null==t&&(t=1),e=+e||0,null==t&&(t=e,e=0),e+et(lt()*((+t||0)-e+1))},n.range=function(e,t,n){e=+e||0,n=+n||1,null==t&&(t=e,e=0);for(var r=-1,t=at(0,Y((t-e)/n)),i=Array(t);++
|
||||
r<t;)i[r]=e,e+=n;return i},n.reduce=A,n.reduceRight=O,n.reject=function(e,t,n){return t=s(t,n),T(e,function(e,n,r){return!t(e,n,r)})},n.rest=H,n.result=function(e,t){var n=e?e[t]:null;return g(n)?e[t]():n},n.shuffle=function(e){var t=-1,n=Array(e?e.length:0);return Lt(e,function(e){var r=et(lt()*(++t+1));n[t]=n[r],n[r]=e}),n},n.size=function(e){var t=e?e.length:0;return"number"==typeof t?t:kt(e).length},n.some=M,n.sortBy=function(e,t,n){var i=[],t=s(t,n);Lt(e,function(e,n,r){i.push({a:t(e,n,r),b:
|
||||
n,c:e})}),e=i.length;for(i.sort(r);e--;)i[e]=i[e].c;return i},n.sortedIndex=B,n.tap=function(e,t){return t(e),e},n.template=function(e,t,r){e||(e="");var r=p({},r,n.templateSettings),i=0,s="__p+='",u=r.variable;e.replace(RegExp((r.escape||K).source+"|"+(r.interpolate||K).source+"|"+(r.evaluate||K).source+"|$","g"),function(t,n,r,u,a){s+=e.slice(i,a).replace(G,o),s+=n?"'+_['escape']("+n+")+'":u?"';"+u+";__p+='":r?"'+((__t=("+r+"))==null?'':__t)+'":"",i=a+t.length}),s+="';\n",u||(u="obj",s="with("+
|
||||
u+"||{}){"+s+"}"),s="function("+u+"){var __t,__p='',__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}"+s+"return __p}";try{var a=Function("_","return "+s)(n)}catch(f){throw f.source=s,f}return t?a(t):(a.source=s,a)},n.throttle=function(e,t){function n(){u=new Date,o=null,i=e.apply(s,r)}var r,i,s,o,u=0;return function(){var a=new Date,f=t-(a-u);return r=arguments,s=this,0>=f?(clearTimeout(o),u=a,i=e.apply(s,r)):o||(o=setTimeout(n,f)),i}},n.times=function(e,t,n){for(var e=+e||0
|
||||
,r=-1,i=Array(e);++r<e;)i[r]=t.call(n,r);return i},n.toArray=function(e){return"number"==typeof (e?e.length:0)?f(e):E(e)},n.unescape=function(e){return null==e?"":(e+"").replace($,l)},n.union=function(){return j(Z.apply(z,arguments))},n.uniq=j,n.uniqueId=function(e){var t=W++;return e?e+t:t},n.values=E,n.where=function(e,t){var n=kt(t);return T(e,function(e){for(var r=n.length;r--;){var i=e[n[r]]===t[n[r]];if(!i)break}return!!i})},n.without=function(e){for(var t=-1,n=e.length,r=[];++t<n;){var i=e
|
||||
[t];0>P(arguments,i,1)&&r.push(i)}return r},n.wrap=function(e,t){return function(){var n=[e];return nt.apply(n,arguments),t.apply(this,n)}},n.zip=function(e){for(var t=-1,n=e?k(L(arguments,"length")):0,r=Array(n);++t<n;)r[t]=L(arguments,t);return r},n.all=x,n.any=M,n.collect=C,n.detect=N,n.drop=H,n.each=Lt,n.extend=c,n.foldl=A,n.foldr=O,n.head=_,n.include=S,n.inject=A,n.methods=d,n.select=T,n.tail=H,n.take=_,n.unique=j,q(n),n.prototype.chain=function(){return this.__chain__=!0,this},n.prototype.value=
|
||||
function(){return this.__wrapped__},Lt("pop push reverse shift sort splice unshift".split(" "),function(e){var t=z[e];n.prototype[e]=function(){var e=this.__wrapped__;return t.apply(e,arguments),bt&&e.length===0&&delete e[0],this}}),Lt(["concat","join","slice"],function(e){var t=z[e];n.prototype[e]=function(){var e=t.apply(this.__wrapped__,arguments);return this.__chain__&&(e=new n(e),e.__chain__=!0),e}}),R?"object"==typeof module&&module&&module.exports==R?(module.exports=n)._=n:R._=n:e._=n})(this
|
||||
);
|
||||
18
lodash.underscore.min.js
vendored
18
lodash.underscore.min.js
vendored
@@ -1,5 +1,5 @@
|
||||
/*!
|
||||
Lo-Dash 0.10.0 (Custom Build) lodash.com/license
|
||||
Lo-Dash 1.0.0-rc.1 (Custom Build) lodash.com/license
|
||||
Build: `lodash underscore -m -o ./lodash.underscore.min.js`
|
||||
Underscore.js 1.4.2 underscorejs.org/LICENSE
|
||||
*/
|
||||
@@ -11,14 +11,14 @@ e,i,s){if(tt.call(s,i))return a++,!(u=tt.call(t,i)&&m(e,t[i],n,r))&&X}),u&&St(t,
|
||||
n}function x(e,t,n){var r=!0,t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i&&(r=!!t(e[n],n,e)););else Lt(e,function(e,n,i){return!(r=!!t(e,n,i))&&X});return r}function T(e,t,n){var r=[],t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i;){var o=e[n];t(o,n,e)&&r.push(o)}else Lt(e,function(e,n,i){t(e,n,i)&&r.push(e)});return r}function N(e,t,n){var r,t=s(t,n);return Lt(e,function(e,n,i){if(t(e,n,i))return r=e,X}),r}function C(e,t,n){var r=-1,i=e?e.length:0,o=Array("number"==typeof i?i:0),t=s(t,n);if(
|
||||
Ct(e))for(;++r<i;)o[r]=t(e[r],r,e);else Lt(e,function(e,n,i){o[++r]=t(e,n,i)});return o}function k(e,t,n){var r=-Infinity,i=-1,o=e?e.length:0,u=r;if(t||!Ct(e))t=s(t,n),Lt(e,function(e,n,i){n=t(e,n,i),n>r&&(r=n,u=e)});else for(;++i<o;)e[i]>u&&(u=e[i]);return u}function L(e,t){return C(e,t+"")}function A(e,t,n,r){var i=3>arguments.length;return t||(t=I),Lt(e,function(e,s,o){n=i?(i=!1,e):t.call(r,n,e,s,o)}),n}function O(e,t,n,r){var i=e?e.length:0,s=3>arguments.length;if("number"!=typeof i)var o=kt(
|
||||
e),i=o.length;return t||(t=I),Lt(e,function(u,a,f){a=o?o[--i]:--i,n=s?(s=!1,e[a]):t.call(r,n,e[a],a,f)}),n}function M(e,t,n){var r,t=s(t,n);if(Ct(e))for(var n=-1,i=e.length;++n<i&&!(r=t(e[n],n,e)););else Lt(e,function(e,n,i){return(r=t(e,n,i))&&X});return!!r}function _(e,t,n){if(e){var r=e.length;return null==t||n?e[0]:f(e,0,ft(at(0,t),r))}}function D(e,t){for(var n=-1,r=e?e.length:0,i=[];++n<r;){var s=e[n];Ct(s)?nt.apply(i,t?s:D(s)):i.push(s)}return i}function P(e,t,n){var r=-1,i=e?e.length:0;if("number"==typeof
|
||||
n)r=(0>n?at(0,i+n):n||0)-1;else if(n)return r=B(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function H(e,t,n){return f(e,null==t||n?1:at(0,t))}function B(e,t,n,r){for(var i=0,o=e?e.length:i,n=n?s(n,r):I,t=n(t);i<o;)r=i+o>>>1,n(e[r])<t?i=r+1:o=r;return i}function j(e,t,n,r){var i=-1,o=e?e.length:0,u=[],a=u;n&&(a=[],n=s(n,r));for(;++i<o;){var r=e[i],f=n?n(r,i,e):r;if(t?!i||a[a.length-1]!==f:0>P(a,f))n&&a.push(f),u.push(r)}return u}function F(e,t){return bt||it&&2<arguments.length?it
|
||||
n)r=(0>n?at(0,i+n):n||0)-1;else if(n)return r=B(e,t),e[r]===t?r:-1;for(;++r<i;)if(e[r]===t)return r;return-1}function H(e,t,n){return f(e,null==t||n?1:at(0,t))}function B(e,t,n,r){for(var i=0,o=e?e.length:i,n=n?s(n,r):I,t=n(t);i<o;)r=i+o>>>1,n(e[r])<t?i=r+1:o=r;return i}function j(e,t,n,r){var i=-1,o=e?e.length:0,u=[],a=u;n&&(a=[],n=s(n,r));for(;++i<o;){var r=e[i],f=n?n(r,i,e):r;if(t?!i||a[a.length-1]!==f:0>P(a,f))n&&a.push(f),u.push(r)}return u}function F(e,t){return yt||it&&2<arguments.length?it
|
||||
.call.apply(it,arguments):i(e,t,f(arguments,2))}function I(e){return e}function q(e){Lt(d(e),function(t){var r=n[t]=e[t];n.prototype[t]=function(){var e=[this.__wrapped__];return nt.apply(e,arguments),e=r.apply(n,e),this.__chain__&&(e=new n(e),e.__chain__=!0),e}})}var R="object"==typeof exports&&exports,U="object"==typeof global&&global;U.global===U&&(e=U);var z=[],U=new function(){},W=0,X=U,V=e._,$=/&(?:amp|lt|gt|quot|#x27);/g,J=RegExp("^"+(U.valueOf+"").replace(/[.*+?^=!:${}()|[\]\/\\]/g,"\\$&"
|
||||
).replace(/valueOf|for [^\]]+/g,".+?")+"$"),K=/($^)/,Q=/[&<>"']/g,G=/['\n\r\t\u2028\u2029\\]/g,Y=Math.ceil,Z=z.concat,et=Math.floor,tt=U.hasOwnProperty,nt=z.push,rt=U.toString,it=J.test(it=f.bind)&&it,st=J.test(st=Array.isArray)&&st,ot=e.isFinite,ut=J.test(ut=Object.keys)&&ut,at=Math.max,ft=Math.min,lt=Math.random,ct="[object Array]",ht="[object Boolean]",pt="[object Date]",dt="[object Number]",vt="[object Object]",mt="[object RegExp]",gt="[object String]",yt=(yt={0:1,length:1},z.splice.call(yt,0
|
||||
,1),yt[0]),bt=it&&/\n|Opera/.test(it+rt.call(e.opera)),wt={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,"undefined":!1},Et={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};n.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,variable:""},n.isArguments=function(e){return"[object Arguments]"==rt.call(e)},n.isArguments(arguments)||(n.isArguments=function(e){return e?tt.call(e,"callee"):!1});var St=function(
|
||||
e,t){var n;if(!e)return e;t||(t=I);for(n in e)if(t(e[n],n,e)===X)break;return e},xt=function(e,t){var n;if(!e)return e;t||(t=I);for(n in e)if(tt.call(e,n)&&t(e[n],n,e)===X)break;return e},Tt={"&":"&","<":"<",">":">",'"':""","'":"'"},Nt=v(Tt),Ct=st||function(e){return rt.call(e)==ct};g(/x/)&&(g=function(e){return"[object Function]"==rt.call(e)});var kt=ut?function(e){return y(e)?ut(e):[]}:h,Lt=function(e,t,n){if(!e)return e;var t=t&&"undefined"==typeof n?t:s(t,n),r=e.length,n=-1
|
||||
;if("number"==typeof r){for(;++n<r;)if(t(e[n],n,e)===X)return e}else for(n in e)if(tt.call(e,n)&&t(e[n],n,e)===X)return e};n.VERSION="0.10.0",n.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},n.bind=F,n.bindAll=function(e){for(var t=arguments,n=1<t.length?0:(t=d(e),-1),r=t.length;++n<r;){var i=t[n];e[i]=F(e[i],e)}return e},n.chain=function(e){return e=new n(e),e.__chain__=!0,e},n.clone=function(e){return e&&wt[typeof e]?Ct(e)?f(e):c({},e):e},n.compact=function(
|
||||
e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r},n.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},n.contains=S,n.countBy=function(e,t,n){var r={},t=s(t,n);return Lt(e,function(e,n,i){n=t(e,n,i),tt.call(r,n)?r[n]++:r[n]=1}),r},n.debounce=function(e,t,n){function r(){u=null,n||(s=e.apply(o,i))}var i,s,o,u;return function(){var a=n&&!u;return i=arguments,o=this,clearTimeout(u),u=setTimeout(r,t
|
||||
),a&&(s=e.apply(o,i)),s}},n.defaults=p,n.defer=function(e){var n=f(arguments,1);return setTimeout(function(){e.apply(t,n)},1)},n.delay=function(e,n){var r=f(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},n.difference=function(e){for(var t=-1,n=e.length,r=Z.apply(z,arguments),i=[];++t<n;){var s=e[t];0>P(r,s,n)&&i.push(s)}return i},n.escape=function(e){return null==e?"":(e+"").replace(Q,u)},n.every=x,n.filter=T,n.find=N,n.first=_,n.flatten=D,n.forEach=Lt,n.functions=d,n.groupBy=function(
|
||||
).replace(/valueOf|for [^\]]+/g,".+?")+"$"),K=/($^)/,Q=/[&<>"']/g,G=/['\n\r\t\u2028\u2029\\]/g,Y=Math.ceil,Z=z.concat,et=Math.floor,tt=U.hasOwnProperty,nt=z.push,rt=U.toString,it=J.test(it=f.bind)&&it,st=J.test(st=Array.isArray)&&st,ot=e.isFinite,ut=J.test(ut=Object.keys)&&ut,at=Math.max,ft=Math.min,lt=Math.random,ct="[object Array]",ht="[object Boolean]",pt="[object Date]",dt="[object Number]",vt="[object Object]",mt="[object RegExp]",gt="[object String]",U=!!e.attachEvent,U=it&&!/\n|true/.test(
|
||||
it+U),yt=it&&!U,bt=(bt={0:1,length:1},z.splice.call(bt,0,1),bt[0]),wt={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,"undefined":!1},Et={"\\":"\\","'":"'","\n":"n","\r":"r"," ":"t","\u2028":"u2028","\u2029":"u2029"};n.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,variable:""},n.isArguments=function(e){return"[object Arguments]"==rt.call(e)},n.isArguments(arguments)||(n.isArguments=function(e){return e?tt.call(e,"callee"):!1});var St=
|
||||
function(e,t){var n;if(!e)return e;t||(t=I);for(n in e)if(t(e[n],n,e)===X)break;return e},xt=function(e,t){var n;if(!e)return e;t||(t=I);for(n in e)if(tt.call(e,n)&&t(e[n],n,e)===X)break;return e},Tt={"&":"&","<":"<",">":">",'"':""","'":"'"},Nt=v(Tt),Ct=st||function(e){return rt.call(e)==ct};g(/x/)&&(g=function(e){return"[object Function]"==rt.call(e)});var kt=ut?function(e){return y(e)?ut(e):[]}:h,Lt=function(e,t,n){if(!e)return e;var t=t&&"undefined"==typeof n?t:s(t,n),r=e.length
|
||||
,n=-1;if("number"==typeof r){for(;++n<r;)if(t(e[n],n,e)===X)return e}else for(n in e)if(tt.call(e,n)&&t(e[n],n,e)===X)return e};n.VERSION="1.0.0-rc.1",n.after=function(e,t){return 1>e?t():function(){if(1>--e)return t.apply(this,arguments)}},n.bind=F,n.bindAll=function(e){for(var t=arguments,n=1<t.length?0:(t=d(e),-1),r=t.length;++n<r;){var i=t[n];e[i]=F(e[i],e)}return e},n.chain=function(e){return e=new n(e),e.__chain__=!0,e},n.clone=function(e){return e&&wt[typeof e]?Ct(e)?f(e):c({},e):e},n.compact=
|
||||
function(e){for(var t=-1,n=e?e.length:0,r=[];++t<n;){var i=e[t];i&&r.push(i)}return r},n.compose=function(){var e=arguments;return function(){for(var t=arguments,n=e.length;n--;)t=[e[n].apply(this,t)];return t[0]}},n.contains=S,n.countBy=function(e,t,n){var r={},t=s(t,n);return Lt(e,function(e,n,i){n=t(e,n,i),tt.call(r,n)?r[n]++:r[n]=1}),r},n.debounce=function(e,t,n){function r(){u=null,n||(s=e.apply(o,i))}var i,s,o,u;return function(){var a=n&&!u;return i=arguments,o=this,clearTimeout(u),u=setTimeout
|
||||
(r,t),a&&(s=e.apply(o,i)),s}},n.defaults=p,n.defer=function(e){var n=f(arguments,1);return setTimeout(function(){e.apply(t,n)},1)},n.delay=function(e,n){var r=f(arguments,2);return setTimeout(function(){e.apply(t,r)},n)},n.difference=function(e){for(var t=-1,n=e.length,r=Z.apply(z,arguments),i=[];++t<n;){var s=e[t];0>P(r,s,n)&&i.push(s)}return i},n.escape=function(e){return null==e?"":(e+"").replace(Q,u)},n.every=x,n.filter=T,n.find=N,n.first=_,n.flatten=D,n.forEach=Lt,n.functions=d,n.groupBy=function(
|
||||
e,t,n){var r={},t=s(t,n);return Lt(e,function(e,n,i){n=t(e,n,i),(tt.call(r,n)?r[n]:r[n]=[]).push(e)}),r},n.has=function(e,t){return e?tt.call(e,t):!1},n.identity=I,n.indexOf=P,n.initial=function(e,t,n){if(!e)return[];var r=e.length;return f(e,0,ft(at(0,r-(null==t||n?1:t||0)),r))},n.intersection=function(e){var t=arguments,n=t.length,r=[];return Lt(e,function(e){if(0>P(r,e)){for(var i=n;--i;)if(0>P(t[i],e))return;r.push(e)}}),r},n.invert=v,n.invoke=function(e,t){var n=f(arguments,2),r="function"==typeof
|
||||
t,i=[];return Lt(e,function(e){i.push((r?t:e[t]).apply(e,n))}),i},n.isArray=Ct,n.isBoolean=function(e){return!0===e||!1===e||rt.call(e)==ht},n.isDate=function(e){return rt.call(e)==pt},n.isElement=function(e){return e?1===e.nodeType:!1},n.isEmpty=function(e){if(!e)return!0;if(Ct(e)||w(e))return!e.length;for(var t in e)if(tt.call(e,t))return!1;return!0},n.isEqual=m,n.isFinite=function(e){return ot(e)&&rt.call(e)==dt},n.isFunction=g,n.isNaN=function(e){return b(e)&&e!=+e},n.isNull=function(e){return null===
|
||||
e},n.isNumber=b,n.isObject=y,n.isRegExp=function(e){return rt.call(e)==mt},n.isString=w,n.isUndefined=function(e){return"undefined"==typeof e},n.keys=kt,n.last=function(e,t,n){if(e){var r=e.length;return null==t||n?e[r-1]:f(e,at(0,r-t))}},n.lastIndexOf=function(e,t,n){var r=e?e.length:0;for("number"==typeof n&&(r=(0>n?at(0,r+n):ft(n,r-1))+1);r--;)if(e[r]===t)return r;return-1},n.map=C,n.max=k,n.memoize=function(e,t){var n={};return function(){var r=t?t.apply(this,arguments):arguments[0];return tt
|
||||
@@ -29,5 +29,5 @@ n,c:e})}),e=i.length;for(i.sort(r);e--;)i[e]=i[e].c;return i},n.sortedIndex=B,n.
|
||||
u+"||{}){"+s+"}"),s="function("+u+"){var __t,__p='',__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}"+s+"return __p}";try{var a=Function("_","return "+s)(n)}catch(f){throw f.source=s,f}return t?a(t):(a.source=s,a)},n.throttle=function(e,t){function n(){u=new Date,o=null,i=e.apply(s,r)}var r,i,s,o,u=0;return function(){var a=new Date,f=t-(a-u);return r=arguments,s=this,0>=f?(clearTimeout(o),u=a,i=e.apply(s,r)):o||(o=setTimeout(n,f)),i}},n.times=function(e,t,n){for(var e=+e||0
|
||||
,r=-1,i=Array(e);++r<e;)i[r]=t.call(n,r);return i},n.toArray=function(e){return"number"==typeof (e?e.length:0)?f(e):E(e)},n.unescape=function(e){return null==e?"":(e+"").replace($,l)},n.union=function(){return j(Z.apply(z,arguments))},n.uniq=j,n.uniqueId=function(e){var t=W++;return e?e+t:t},n.values=E,n.where=function(e,t){var n=kt(t);return T(e,function(e){for(var r=n.length;r--;){var i=e[n[r]]===t[n[r]];if(!i)break}return!!i})},n.without=function(e){for(var t=-1,n=e.length,r=[];++t<n;){var i=e
|
||||
[t];0>P(arguments,i,1)&&r.push(i)}return r},n.wrap=function(e,t){return function(){var n=[e];return nt.apply(n,arguments),t.apply(this,n)}},n.zip=function(e){for(var t=-1,n=e?k(L(arguments,"length")):0,r=Array(n);++t<n;)r[t]=L(arguments,t);return r},n.all=x,n.any=M,n.collect=C,n.detect=N,n.drop=H,n.each=Lt,n.extend=c,n.foldl=A,n.foldr=O,n.head=_,n.include=S,n.inject=A,n.methods=d,n.select=T,n.tail=H,n.take=_,n.unique=j,q(n),n.prototype.chain=function(){return this.__chain__=!0,this},n.prototype.value=
|
||||
function(){return this.__wrapped__},Lt("pop push reverse shift sort splice unshift".split(" "),function(e){var t=z[e];n.prototype[e]=function(){var e=this.__wrapped__;return t.apply(e,arguments),yt&&e.length===0&&delete e[0],this}}),Lt(["concat","join","slice"],function(e){var t=z[e];n.prototype[e]=function(){var e=t.apply(this.__wrapped__,arguments);return this.__chain__&&(e=new n(e),e.__chain__=!0),e}}),R?"object"==typeof module&&module&&module.exports==R?(module.exports=n)._=n:R._=n:e._=n})(this
|
||||
function(){return this.__wrapped__},Lt("pop push reverse shift sort splice unshift".split(" "),function(e){var t=z[e];n.prototype[e]=function(){var e=this.__wrapped__;return t.apply(e,arguments),bt&&e.length===0&&delete e[0],this}}),Lt(["concat","join","slice"],function(e){var t=z[e];n.prototype[e]=function(){var e=t.apply(this.__wrapped__,arguments);return this.__chain__&&(e=new n(e),e.__chain__=!0),e}}),R?"object"==typeof module&&module&&module.exports==R?(module.exports=n)._=n:R._=n:e._=n})(this
|
||||
);
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "lodash",
|
||||
"version": "0.10.0",
|
||||
"version": "1.0.0-rc.1",
|
||||
"description": "A drop-in replacement for Underscore.js delivering performance, bug fixes, and additional features.",
|
||||
"homepage": "http://lodash.com",
|
||||
"main": "./lodash",
|
||||
|
||||
@@ -1600,7 +1600,7 @@
|
||||
/*--------------------------------------------------------------------------*/
|
||||
|
||||
suites.push(
|
||||
Benchmark.Suite('`_.toArray` with an array')
|
||||
Benchmark.Suite('`_.toArray` with an array (edge case)')
|
||||
.add(buildName, '\
|
||||
lodash.toArray(numbers)'
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user