UNPKG

@nknahom/lotide

Version:

Lotide is mini clone of the Lodash (https://lodash.com) library for learning JavaScript. What is Lodash? Lodash is a library that makes JavaScript easier by taking the hassle out of working with arrays, numbers, objects, strings, etc.

16 lines (14 loc) 314 B
const eqArrays = function (array1, array2) { let isEqual = true; if (array1.length === array2.length) { array1.forEach((element, index) => { if (element !== array2[index]) { isEqual = false; } }); } else { isEqual = false; } return isEqual; }; module.exports = eqArrays;