WebStorm IDE で ESLint を動作させようとしています。構成ファイルとエラーを提供しています。
エラー
エラー: /usr/local/lib/node_modules/eslint-config-airbnb/rules/react.js: ルール "react/jsx-boolean-value" の構成が無効です: 値 "never,[object Object]" は持つべきではありません1 個以上のアイテム。参照元: /usr/local/lib/node_modules/eslint-config-airbnb/index.js 参照元: /Users/xxx/WebstormProjects/xx-xx-ui/xx/code/.eslintrc.js at validateRuleOptions (/usr /local/lib/node_modules/eslint/lib/config/config-validator.js:113:15)
.eslintrc.js
module.exports = {
"extends": "airbnb",
"rules": {
"import/extensions": 1,
"import/first": 1,
"import/prefer-default-export": 1,
"max-len": 1,
"no-case-declarations": 1,
"no-console": 1,
"no-empty": 0,
"no-fallthrough": 1,
"no-mixed-spaces-and-tabs": 1,
"no-param-reassign": 0,
"no-tabs": 1,
"no-undef": 0,
"no-unused-vars": 1,
"one-var": 1,
"prefer-const": 1,
}
};
パッケージ.json
これらは開発依存関係です
"eslint-config-airbnb": "^15.1.0",
"eslint-plugin-import": "^2.7.0",
"eslint-plugin-jsx-a11y": "^5.1.1",
"eslint-plugin-react": "^7.4.0",