You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
403 B
24 lines
403 B
2 years ago
|
/**
|
||
|
* Enables the wrapper to be iterable.
|
||
|
*
|
||
|
* @name Symbol.iterator
|
||
|
* @memberOf _
|
||
|
* @since 4.0.0
|
||
|
* @category Seq
|
||
|
* @returns {Object} Returns the wrapper object.
|
||
|
* @example
|
||
|
*
|
||
|
* var wrapped = _([1, 2]);
|
||
|
*
|
||
|
* wrapped[Symbol.iterator]() === wrapped;
|
||
|
* // => true
|
||
|
*
|
||
|
* Array.from(wrapped);
|
||
|
* // => [1, 2]
|
||
|
*/
|
||
|
function wrapperToIterator() {
|
||
|
return this;
|
||
|
}
|
||
|
|
||
|
module.exports = wrapperToIterator;
|