Frontmatter
| id | 5024 |
| title | controller.Base: onHashChange() => wrong usage of `every()` |
| state | Closed |
| labels | bugstale |
| assignees | ThorstenRaab |
| createdAt | Oct 17, 2023, 4:39 PM |
| updatedAt | Sep 13, 2024, 4:28 AM |
| githubUrl | https://github.com/neomjs/neo/issues/5024 |
| author | tobiu |
| commentsCount | 2 |
| parentIssue | null |
| subIssues | [] |
| subIssuesCompleted | 0 |
| subIssuesTotal | 0 |
| blockedBy | [] |
| blocking | [] |
| closedAt | Sep 13, 2024, 4:28 AM |
controller.Base: onHashChange() => wrong usage of every()
tobiu assigned to @ThorstenRaab on Oct 17, 2023, 4:39 PM
ThorstenRaab cross-referenced by PR #5043 on Oct 19, 2023, 4:17 PM
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/every
is designed to test all entries of an array with a callback fn to check if they match a given condition.
you can use
forEach()in case you just want to iterate over all items.if you want to iterate up to a given point and then break the loop, for of is a good fit: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for...of