-
Notifications
You must be signed in to change notification settings - Fork 3.9k
[$250] Enable no-array-for-each lint rule #67422
Copy link
Copy link
Closed
Labels
Awaiting PaymentAuto-added when associated PR is deployed to productionAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.Something is broken. Auto assigns a BugZero manager.ExternalAdded to denote the issue can be worked on by a contributorAdded to denote the issue can be worked on by a contributorWeeklyKSv2KSv2
Metadata
Metadata
Labels
Awaiting PaymentAuto-added when associated PR is deployed to productionAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.Something is broken. Auto assigns a BugZero manager.ExternalAdded to denote the issue can be worked on by a contributorAdded to denote the issue can be worked on by a contributorWeeklyKSv2KSv2
Type
Fields
Give feedbackNo fields configured for issues without a type.
Projects
StatusShow more project fields
Done
Coming from #67420
Problem
When .forEach() is used, then we incur unnecessary performance overhead because function calls are used for each loop iteration, and it is impossible to stop iteration early.
Solution
Enable eslint-plugin-unicorn’s no-array-for-each rule to enforce that plain for or for-of loops are used instead of .forEach loops.
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @greg-schroeder