From 0b9078d034530889a5f00c319a5b7a75c2de940c Mon Sep 17 00:00:00 2001 From: Laurent Cozic Date: Mon, 29 Jul 2019 15:58:17 +0200 Subject: [PATCH] config --- .eslintrc.js | 3 +++ package-lock.json | 39 +++++++++++++++++++++++++++++++++++++++ package.json | 1 + 3 files changed, 43 insertions(+) diff --git a/.eslintrc.js b/.eslintrc.js index 40980292b..352709e43 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -22,9 +22,12 @@ module.exports = { "no-constant-condition": 0, "no-prototype-builtins": 0, "prettier/prettier": "error", + // Uncomment this to automatically remove unused requires: + // "autofix/no-unused-vars": "error", }, "plugins": [ "react", "prettier", + "autofix", ], }; \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 7645cbd34..99919284d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -314,6 +314,33 @@ "get-stdin": "^6.0.0" } }, + "eslint-plugin-autofix": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/eslint-plugin-autofix/-/eslint-plugin-autofix-0.0.8.tgz", + "integrity": "sha512-UJrI8VFrmLiANrxBkUOgRhzuR9PIHbjsCfwsql+rDz16H3Qri0HsbYXFnTDxdis0bg6WpyFkBLLSiQ6x/w065g==", + "dev": true, + "requires": { + "eslint-rule-composer": "^0.3.0", + "espree": "^5.0.1", + "esutils": "^2.0.2", + "lodash": "^4.17.11", + "string-similarity": "^3.0.0", + "v8-compile-cache": "^2.0.3" + }, + "dependencies": { + "espree": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/espree/-/espree-5.0.1.tgz", + "integrity": "sha512-qWAZcWh4XE/RwzLJejfcofscgMc9CamR6Tn1+XRXNzrvUSSbiAjGOI/fggztjIi7y9VLPqnICMIPiGyr8JaZ0A==", + "dev": true, + "requires": { + "acorn": "^6.0.7", + "acorn-jsx": "^5.0.0", + "eslint-visitor-keys": "^1.0.0" + } + } + } + }, "eslint-plugin-prettier": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-3.1.0.tgz", @@ -351,6 +378,12 @@ } } }, + "eslint-rule-composer": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/eslint-rule-composer/-/eslint-rule-composer-0.3.0.tgz", + "integrity": "sha512-bt+Sh8CtDmn2OajxvNO+BX7Wn4CIWMpTRm3MaiKPCQcnnlm0CS2mhui6QaoeQugs+3Kj2ESKEEGJUdVafwhiCg==", + "dev": true + }, "eslint-scope": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.0.0.tgz", @@ -1098,6 +1131,12 @@ "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", "dev": true }, + "string-similarity": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/string-similarity/-/string-similarity-3.0.0.tgz", + "integrity": "sha512-7kS7LyTp56OqOI2BDWQNVnLX/rCxIQn+/5M0op1WV6P8Xx6TZNdajpuqQdiJ7Xx+p1C5CsWMvdiBp9ApMhxzEQ==", + "dev": true + }, "string-width": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", diff --git a/package.json b/package.json index 6029c69f9..7b74be6e3 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,7 @@ "devDependencies": { "eslint": "^6.1.0", "eslint-config-prettier": "^6.0.0", + "eslint-plugin-autofix": "0.0.8", "eslint-plugin-prettier": "^3.1.0", "eslint-plugin-react": "^7.14.3", "prettier": "1.18.2"