According to the documentation for indent, there is a FunctionDeclaration property taking an object. I would like to set the parameters property of FunctionDeclaration to 2. However, I still get an error about my indentation being wrong.
I suspect my format in the eslint settings file is wrong. I've tried looking in the documentation and elsewhere for a sample of a complete setting for indent to make sure my formatting is right, but I can't find any. Here is the relevant part of the setting file:
"indent": [
"error",
"tab",
{
"FunctionDeclaration": {
"body": 1,
"parameters": 2
},
"SwitchCase": 1
}
],
The SwitchCase property and all the others are working just fine, so it's strange that this one property in particular isn't working. I also tried setting both body and parameters to various values but that seems to have no effect whatsoever on eslint's errors.
Edit:
Code causing the error:
constructor(word, countable = true, proper = false, alwaysSingular = false,
alwaysPlural = false, irregularPlural = false, definite = false, indefinite = false){
Again, I get the same error regardless of the numbers I put into body and parameters, but don't get an error if I set the indentation in the code to one indent.
eslint version 6.14.4