rome/tools

馃搸 `useForOf`, prefer-for-of, @typescript-eslint/prefer-for-of

Open

#4,174 opened on Jan 24, 2023

View on GitHub
聽(2 comments)聽(0 reactions)聽(0 assignees)Rust聽(23,438 stars)聽(647 forks)batch import
A-LinterHelp wantedI-Normalgood first issuetask

Description

Description

https://typescript-eslint.io/rules/prefer-for-of

This rule forces loop functions to use for of if the index of a for loop is never used, greatly improving readability and ensuring there are no unused variables being referenced (in this case, the index variable).

Contributor guide

馃搸 `useForOf`, prefer-for-of, @typescript-eslint/prefer-for-of 路 rome/tools#4174 | Good First Issue