Skip to content
This repository was archived by the owner on Mar 7, 2019. It is now read-only.

Commit aade9a7

Browse files
feat(rule): add array-element-newline
1 parent 6792836 commit aade9a7

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

coding-styles/fixable.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ module.exports = {
2525
// bracket in the pair has a linebreak inside it and the other bracket does not.
2626
'array-bracket-newline': ['warn', 'consistent'],
2727

28+
// enforce line breaks between array elements
29+
// A number of style guides require or disallow line breaks between array elements. This ruleset
30+
// requires consistent usage of linebreaks between array elements.
31+
'array-element-newline': ['warn', 'consistent'],
32+
2833
// Require braces in arrow function body
2934
// This rule can enforce the use of braces around arrow function body.
3035
'arrow-body-style': ['warn', 'as-needed'],

unused.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@
1010

1111
module.exports = {
1212
rules: {
13-
// Enforce line breaks between array elements
14-
// Unused, too restrictive
15-
'array-element-newline': 0,
16-
1713
// Treat var as Block Scoped
1814
// Unused in favour of `no-var` rule. Front-end could have some interest in this rule.
1915
'block-scoped-var': 0,

0 commit comments

Comments
 (0)