summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorValentin Popov <info@valentineus.link>2020-02-14 11:02:05 +0300
committerValentin Popov <info@valentineus.link>2020-02-14 11:02:05 +0300
commit9a518ccf7e50deb0ce80bd8b332baff6e6881278 (patch)
tree5e0b43c563f875ba267120032ab63c79c8071c50
parent059976ca5a189f20c42875346021246b5789907f (diff)
downloadeslint-config-9a518ccf7e50deb0ce80bd8b332baff6e6881278.tar.xz
eslint-config-9a518ccf7e50deb0ce80bd8b332baff6e6881278.zip
feat(eslint): Rule "no-use-before-define"
Signed-off-by: Valentin Popov <info@valentineus.link>
-rw-r--r--ROADMAP.md2
-rw-r--r--src/rules/default.json8
2 files changed, 9 insertions, 1 deletions
diff --git a/ROADMAP.md b/ROADMAP.md
index 9ffc03a..333f140 100644
--- a/ROADMAP.md
+++ b/ROADMAP.md
@@ -206,7 +206,7 @@
- [ ] "no-unused-expressions"
- [ ] "no-unused-labels"
- [X] "no-unused-vars"
-- [ ] "no-use-before-define"
+- [X] "no-use-before-define"
- [ ] "no-useless-backreference"
- [X] "no-useless-call"
- [ ] "no-useless-catch"
diff --git a/src/rules/default.json b/src/rules/default.json
index 98937aa..233828e 100644
--- a/src/rules/default.json
+++ b/src/rules/default.json
@@ -397,6 +397,14 @@
"vars": "all"
}
],
+ "no-use-before-define": [
+ "error",
+ {
+ "classes": true,
+ "functions": true,
+ "variables": true
+ }
+ ],
"no-useless-call": [
"error"
],