diff --git a/eslintrc.json b/eslintrc.json index 27f9598f..5bbae11b 100644 --- a/eslintrc.json +++ b/eslintrc.json @@ -9,12 +9,13 @@ "settings": { "react": { - "version": "detect" + "version": "latest" } }, "plugins": [ - "react" + "react", + "react-hooks" ], "extends": [ @@ -31,6 +32,8 @@ "react/no-unknown-property": "error", "react/no-unused-prop-types": "error", "react/prop-types": "error", - "react/react-in-jsx-scope": "error" + "react/react-in-jsx-scope": "error", + "react-hooks/rules-of-hooks": "error", + "react-hooks/exhaustive-deps": "warn" } } diff --git a/package.json b/package.json index f1f589ac..e8eb9b65 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "eslint-config-standard-react", "description": "JavaScript Standard Style React/JSX support - ESLint Shareable Config", - "version": "9.2.0", + "version": "10.0.0", "author": { "name": "Feross Aboukhadijeh", "email": "feross@feross.org", @@ -11,12 +11,17 @@ "url": "https://github.com/feross/eslint-config-standard-react/issues" }, "dependencies": { - "eslint-config-standard-jsx": "^8.0.0" + "eslint-config-standard-jsx": "^8.1.0" }, "devDependencies": { - "eslint": "^6.2.2", - "eslint-plugin-react": "^7.6.1", - "tape": "^4.8.0" + "eslint": "^7.7.0", + "eslint-plugin-react": "^7.20.6", + "eslint-plugin-react-hooks": "^4.1.0", + "tape": "^5.0.1" + }, + "peerDependencies": { + "eslint": ">=7.7.0", + "eslint-plugin-react": ">=7.20.6" }, "homepage": "https://github.com/feross/eslint-config-standard-react", "keywords": [ @@ -49,10 +54,6 @@ ], "license": "MIT", "main": "index.js", - "peerDependencies": { - "eslint": ">=6.2.2", - "eslint-plugin-react": ">=7.6.1" - }, "repository": { "type": "git", "url": "git://github.com/feross/eslint-config-standard-react.git"