From 3c3074e502dc9ebc7dbdad372df474e49f52d512 Mon Sep 17 00:00:00 2001 From: Jordan Harband Date: Tue, 20 Feb 2018 00:10:46 -0800 Subject: [PATCH] [eslint config] [*] [deps] update `eslint`, `eslint-find-rules`, `eslint-plugin-react`, `tape` --- packages/eslint-config-airbnb-base/package.json | 6 +++--- packages/eslint-config-airbnb/package.json | 12 ++++++------ packages/eslint-config-airbnb/rules/react.js | 7 ++++++- 3 files changed, 15 insertions(+), 10 deletions(-) diff --git a/packages/eslint-config-airbnb-base/package.json b/packages/eslint-config-airbnb-base/package.json index 5d4cd5ccc5..a3d13d59f0 100644 --- a/packages/eslint-config-airbnb-base/package.json +++ b/packages/eslint-config-airbnb-base/package.json @@ -51,12 +51,12 @@ "babel-preset-airbnb": "^2.4.0", "babel-tape-runner": "^2.0.1", "editorconfig-tools": "^0.1.1", - "eslint": "^4.16.0", - "eslint-find-rules": "^3.1.1", + "eslint": "^4.18.0", + "eslint-find-rules": "^3.2.0", "eslint-plugin-import": "^2.8.0", "in-publish": "^2.0.0", "safe-publish-latest": "^1.1.1", - "tape": "^4.8.0" + "tape": "^4.9.0" }, "peerDependencies": { "eslint": "^4.16.0", diff --git a/packages/eslint-config-airbnb/package.json b/packages/eslint-config-airbnb/package.json index 0e52b0e0ea..66c0b8294c 100644 --- a/packages/eslint-config-airbnb/package.json +++ b/packages/eslint-config-airbnb/package.json @@ -54,21 +54,21 @@ "babel-preset-airbnb": "^2.4.0", "babel-tape-runner": "^2.0.1", "editorconfig-tools": "^0.1.1", - "eslint": "^4.16.0", - "eslint-find-rules": "^3.1.1", + "eslint": "^4.18.0", + "eslint-find-rules": "^3.2.0", "eslint-plugin-import": "^2.8.0", "eslint-plugin-jsx-a11y": "^6.0.3", - "eslint-plugin-react": "^7.6.1", + "eslint-plugin-react": "^7.7.0", "in-publish": "^2.0.0", "react": ">= 0.13.0", "safe-publish-latest": "^1.1.1", - "tape": "^4.8.0" + "tape": "^4.9.0" }, "peerDependencies": { - "eslint": "^4.16.0", + "eslint": "^4.18.0", "eslint-plugin-import": "^2.8.0", "eslint-plugin-jsx-a11y": "^6.0.3", - "eslint-plugin-react": "^7.6.1" + "eslint-plugin-react": "^7.7.0" }, "engines": { "node": ">= 4" diff --git a/packages/eslint-config-airbnb/rules/react.js b/packages/eslint-config-airbnb/rules/react.js index 6332546b26..7d8145a17a 100644 --- a/packages/eslint-config-airbnb/rules/react.js +++ b/packages/eslint-config-airbnb/rules/react.js @@ -371,7 +371,8 @@ module.exports = { // Forbids using non-exported propTypes // https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/forbid-foreign-prop-types.md - 'react/forbid-foreign-prop-types': 'off', + // TODO: enable? + 'react/forbid-foreign-prop-types': ['off', { allowInPropTypes: true }], // Prevent void DOM elements from receiving children // https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/void-dom-elements-no-children.md @@ -431,6 +432,10 @@ module.exports = { // Prevent this from being used in stateless functional components // https://github.com/yannickcr/eslint-plugin-react/blob/843d71a432baf0f01f598d7cf1eea75ad6896e4b/docs/rules/no-this-in-sfc.md 'react/no-this-in-sfc': 'error', + + // Validate JSX maximum depth + // https://github.com/yannickcr/eslint-plugin-react/blob/abe8381c0d6748047224c430ce47f02e40160ed0/docs/rules/jsx-max-depth.md + 'react/jsx-max-depth': 'off', }, settings: {