mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-10 02:47:50 +00:00
Bump to v3.0.0.
This commit is contained in:
20
internal/lazyReverse.js
Normal file
20
internal/lazyReverse.js
Normal file
@@ -0,0 +1,20 @@
|
||||
import LazyWrapper from './LazyWrapper';
|
||||
|
||||
/**
|
||||
* Reverses the direction of lazy iteration.
|
||||
*
|
||||
* @private
|
||||
* @name reverse
|
||||
* @memberOf LazyWrapper
|
||||
* @returns {Object} Returns the new reversed `LazyWrapper` object.
|
||||
*/
|
||||
function lazyReverse() {
|
||||
var filtered = this.filtered,
|
||||
result = filtered ? new LazyWrapper(this) : this.clone();
|
||||
|
||||
result.dir = this.dir * -1;
|
||||
result.filtered = filtered;
|
||||
return result;
|
||||
}
|
||||
|
||||
export default lazyReverse;
|
||||
Reference in New Issue
Block a user