Skip to content

Commit

Permalink
docs: add more examples for array-element-newline rule (#15427)
Browse files Browse the repository at this point in the history
  • Loading branch information
snitin315 committed Dec 14, 2021
1 parent f2c7ba6 commit a53e59e
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion docs/rules/array-element-newline.md
Expand Up @@ -42,7 +42,12 @@ Examples of **incorrect** code for this rule with the default `"always"` option:

var c = [1, 2];
var d = [1, 2, 3];
var e = [
var e = [1, 2, 3
];
var f = [
1, 2, 3
];
var g = [
function foo() {
dosomething();
}, function bar() {
Expand All @@ -63,6 +68,11 @@ var c = [1,
var d = [1,
2,
3];
var d = [
1,
2,
3
];
var e = [
function foo() {
dosomething();
Expand Down Expand Up @@ -109,6 +119,11 @@ var b = [1];
var c = [1, 2];
var d = [1, 2, 3];
var e = [
1, 2, 3];
var f = [
1, 2, 3
];
var g = [
function foo() {
dosomething();
}, function bar() {
Expand Down

0 comments on commit a53e59e

Please sign in to comment.