eslint-plugin-ext
eslint extended rules
Install
npm i eslint-plugin-ext -D
Edit .eslintrc.json
:
Rules
lines-between-object-properties
require or disallow an empty line between object properties.
Modified from lines-between-class-members.
It has same options as lines-between-class-members
, and one extra option exceptBetweenSingleLines
.
/* eslint ext/lines-between-object-properties: ["error", "always", { "exceptBetweenSingleLines": true }] */ // badconst foo = a: 1 b: 2 { } { } // goodconst foo = a: 1 b: 2 { } { }