Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

what is the name of the eslint rule to prevent empty lines after or before a curly brace?

What is the name of the eslint rule that will prevent empty lines after or before a curly brace ?

class Foo {
// prevent empty lines
bar() {
}
// prevent empty lines
}
like image 990
Lev Avatar asked Oct 12 '25 07:10

Lev


2 Answers

The rule is "padded-blocks" and not "padding-line-between-statements"

More info : https://eslint.org/docs/rules/padded-blocks

like image 172
lud Avatar answered Oct 13 '25 20:10

lud


"padding-line-between-statements"

Details: https://eslint.org/docs/rules/padding-line-between-statements

like image 39
anonymous Avatar answered Oct 13 '25 21:10

anonymous



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!