javascriptreactjseslint-config-airbnb

ESLint: Spacing around equal sign


I'm using airbnb for my base ESLint, but I noticed it doesn't seem to tag whitespace violations like it used too:

state={

Should raise an issue and be correct to:

state = {

Same with functions:

toggleSidebar=() => {

Which should be:

toggleSidebar = () => {

What's the rule to fix this and why did they stop flagging it?


Solution

  • Check the space-infix-ops rule