Disallows space after object keys.
Types: Boolean
, String
, or Object
Values:
true
"ignoreSingleLine"
ignores objects if the object only takes up a single line
(deprecated use "allExcept": [ "singleline" ]
)"ignoreMultiLine"
ignores objects if the object takes up multiple lines
(deprecated use "allExcept": [ "multiline" ]
)Object
:"allExcept"
: array of exceptions:"singleline"
ignores objects if the object only takes up a single line"multiline"
ignores objects if the object takes up multiple lines"aligned"
ignores aligned object properties"method"
ignores method declarations"disallowSpaceAfterObjectKeys": true
true
var x = {a: 1};
var y = {
a: 1,
b: 2
}
{ allExcept: ['singleline'] }
var x = {a : 1};
var y = {
a: 1,
b: 2
}
{ allExcept: ['multiline'] }
var x = {a: 1};
var y = {
a : 1,
b : 2
}
{ allExcept: ['aligned'] }
var y = {
abc: 1,
d : 2
}
{ allExcept: ['method'] }
var y = {
fn () {
return 42;
}
}
var x = {a : 1};