aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorValentin Popov <info@valentineus.link>2020-02-14 00:20:54 +0300
committerValentin Popov <info@valentineus.link>2020-02-14 00:20:54 +0300
commit228ad3183cdbed0b9fde2a1baa589416db530225 (patch)
tree8d36518bb87b475a8583d2bf621b324cb6adfba8
parent43ccb96a99b1ba335511b2d45eae50c3f0d664ee (diff)
downloadeslint-config-228ad3183cdbed0b9fde2a1baa589416db530225.tar.xz
eslint-config-228ad3183cdbed0b9fde2a1baa589416db530225.zip
feat(eslint): Rule "no-constant-condition"
Signed-off-by: Valentin Popov <info@valentineus.link>
-rw-r--r--ROADMAP.md2
-rw-r--r--src/rules/default.json6
2 files changed, 7 insertions, 1 deletions
diff --git a/ROADMAP.md b/ROADMAP.md
index 1e6ec8a..e78818c 100644
--- a/ROADMAP.md
+++ b/ROADMAP.md
@@ -92,7 +92,7 @@
- [ ] "no-confusing-arrow"
- [X] "no-console"
- [ ] "no-const-assign"
-- [ ] "no-constant-condition"
+- [X] "no-constant-condition"
- [ ] "no-constructor-return"
- [ ] "no-continue"
- [ ] "no-control-regex"
diff --git a/src/rules/default.json b/src/rules/default.json
index 963e9dc..6df0efe 100644
--- a/src/rules/default.json
+++ b/src/rules/default.json
@@ -194,6 +194,12 @@
"no-console": [
"warn"
],
+ "no-constant-condition": [
+ "error",
+ {
+ "checkLoops": true
+ }
+ ],
"no-debugger": [
"warn"
],