DEV Community

Discussion on: Write Cleaner JavaScript Code With .some() And .every() Array Methods

Collapse
 
thepeoplesbourgeois profile image
Josh • Edited

Nice write-up! There's an added benefit to using some and every over the forEach loop in that some stops iterating as soon as it finds a true value, and every stops as soon as it finds a false 😊