Version 1
[yaffs-website] / node_modules / uncss / node_modules / lodash / internal / arrayEach.js
diff --git a/node_modules/uncss/node_modules/lodash/internal/arrayEach.js b/node_modules/uncss/node_modules/lodash/internal/arrayEach.js
new file mode 100644 (file)
index 0000000..c302e63
--- /dev/null
@@ -0,0 +1,22 @@
+/**
+ * A specialized version of `_.forEach` for arrays without support for
+ * iteratee shorthands.
+ *
+ * @private
+ * @param {Array} array The array to iterate over.
+ * @param {Function} iteratee The function invoked per iteration.
+ * @returns {Array} Returns `array`.
+ */
+function arrayEach(array, iteratee) {
+  var index = -1,
+      length = array.length;
+
+  while (++index < length) {
+    if (iteratee(array[index], index, array) === false) {
+      break;
+    }
+  }
+  return array;
+}
+
+module.exports = arrayEach;