Closed bharbron closed 5 years ago
Additionally, should look at replacing almost every instance of for
loops with .map()
or .forEach()
(whichever is appropriate to the use case). This is less critical and more for code cleanliness.
This is done
Downside of learning as I code: using some things incorrectly. There's a lot of places in code where I'm iterating over arrays using
.map()
where I should be using.forEach()
(or maybe even.reduce()
) instead. Basically, it's anyplace where I'm not actually trying to build a new array, I'm just trying to perform an action on each item in an array.Fix this! Bad javascript abounds!