aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorValentin Popov <info@valentineus.link>2020-02-13 22:40:56 +0300
committerValentin Popov <info@valentineus.link>2020-02-13 22:40:56 +0300
commit6c7cf2ef0997913a48051519961c867591307744 (patch)
treecd32b9d6160e523a9338750c7bdebbc610fce340
parentc1a74da765329f074d3bd8b2a80282cace1f684d (diff)
downloadeslint-config-6c7cf2ef0997913a48051519961c867591307744.tar.xz
eslint-config-6c7cf2ef0997913a48051519961c867591307744.zip
feat(eslint): Rule "max-lines-per-function"
Signed-off-by: Valentin Popov <info@valentineus.link>
-rw-r--r--ROADMAP.md2
-rw-r--r--src/rules/default.json9
2 files changed, 10 insertions, 1 deletions
diff --git a/ROADMAP.md b/ROADMAP.md
index 6bc1a3d..011ef65 100644
--- a/ROADMAP.md
+++ b/ROADMAP.md
@@ -65,7 +65,7 @@
- [ ] "max-depth"
- [X] "max-len"
- [X] "max-lines"
-- [ ] "max-lines-per-function"
+- [X] "max-lines-per-function"
- [ ] "max-nested-callbacks"
- [ ] "max-params"
- [X] "max-statements"
diff --git a/src/rules/default.json b/src/rules/default.json
index cc57b61..dd4523a 100644
--- a/src/rules/default.json
+++ b/src/rules/default.json
@@ -155,6 +155,15 @@
"max-lines": [
"off"
],
+ "max-lines-per-function": [
+ "warn",
+ {
+ "IIFEs": false,
+ "max": 128,
+ "skipBlankLines": true,
+ "skipComments": true
+ }
+ ],
"max-statements": [
"off"
],