summaryrefslogtreecommitdiff
path: root/bin/wiki/ImportarDesdeURL/node_modules/lodash/next.js
diff options
context:
space:
mode:
Diffstat (limited to 'bin/wiki/ImportarDesdeURL/node_modules/lodash/next.js')
-rw-r--r--bin/wiki/ImportarDesdeURL/node_modules/lodash/next.js35
1 files changed, 35 insertions, 0 deletions
diff --git a/bin/wiki/ImportarDesdeURL/node_modules/lodash/next.js b/bin/wiki/ImportarDesdeURL/node_modules/lodash/next.js
new file mode 100644
index 00000000..55f949c8
--- /dev/null
+++ b/bin/wiki/ImportarDesdeURL/node_modules/lodash/next.js
@@ -0,0 +1,35 @@
+var toArray = require('./toArray');
+
+/**
+ * Gets the next value on a wrapped object following the
+ * [iterator protocol](https://mdn.io/iteration_protocols#iterator).
+ *
+ * @name next
+ * @memberOf _
+ * @since 4.0.0
+ * @category Seq
+ * @returns {Object} Returns the next iterator value.
+ * @example
+ *
+ * var wrapped = _([1, 2]);
+ *
+ * wrapped.next();
+ * // => { 'done': false, 'value': 1 }
+ *
+ * wrapped.next();
+ * // => { 'done': false, 'value': 2 }
+ *
+ * wrapped.next();
+ * // => { 'done': true, 'value': undefined }
+ */
+function wrapperNext() {
+ if (this.__values__ === undefined) {
+ this.__values__ = toArray(this.value());
+ }
+ var done = this.__index__ >= this.__values__.length,
+ value = done ? undefined : this.__values__[this.__index__++];
+
+ return { 'done': done, 'value': value };
+}
+
+module.exports = wrapperNext;