1.2.0 • Published 2 years ago

eslint-plugin-no-cstyle-for-loop v1.2.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

eslint-plugin-no-cstyle-for-loop

An eslint plugin that does not allow c-style for loops.

❌ Incorrect

for(let i = 0; i < 10; i++) {
  console.log(i);
}

✅ Correct

for(let i of [1, 2, 3]) {
  console.log(i);
}

Installation

npm install --save-dev eslint-plugin-no-cstyle-for-loop

Usage

// .eslintrc.js
{
  "plugins": ["no-cstyle-for-loop"],
  "rules": {
    "no-cstyle-for-loop/noForLoop": "error"
  }
}
1.2.0

2 years ago

1.1.0

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago