node-wot icon indicating copy to clipboard operation
node-wot copied to clipboard

chore: add `guard-for-in` eslint rule

Open JKRhb opened this issue 1 year ago • 3 comments

(Not only) in the context of #1177, I noticed that some of the for loops use the for ... in syntax instead of the for ... of syntax. Apparently, the former style is discouraged and not recommended by eslint, for example (see https://eslint.org/docs/latest/rules/guard-for-in).

This PR replaces the code lines in question and enforces the new style by activating the guard-for-in eslint rule.

JKRhb avatar Jan 06 '24 01:01 JKRhb