Skip to content

Commit aea7269

Browse files
committed
tools: require function declarations
Except for arrow functions, require function declarations instead of function expressions via linting. This is the predominant style in our code base (77 instances of expressions to 2344 instances of declarations). PR-URL: #12711 Reviewed-By: Vse Mozhet Byt <[email protected]> Reviewed-By: Gibson Fahnestock <[email protected]>
1 parent a180259 commit aea7269

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

.eslintrc.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ rules:
9797
eol-last: 2
9898
func-call-spacing: 2
9999
func-name-matching: 2
100+
func-style: [2, declaration, {allowArrowFunctions: true}]
100101
indent: [2, 2, {ArrayExpression: first,
101102
CallExpression: {arguments: first},
102103
MemberExpression: 1,

0 commit comments

Comments
 (0)