Bug 1558517 - Pre 3.2: Disable conflicting eslint:recommended rules by extending eslint-config-prettier, r=standard8
authorVictor Porof <vporof@mozilla.com>
Tue, 11 Jun 2019 16:07:08 +0200
changeset 541023 be08adefd6e42f1c7d7e54126683109bc45e36cd
parent 541022 cca4e4c511dd3c4fc270a1d0b33a081e2edfa7b0
child 541024 f4cf776be93103c4a7fe29d1a065f5220afa8e0d
push id11533
push userarchaeopteryx@coole-files.de
push dateMon, 08 Jul 2019 18:18:03 +0000
treeherdermozilla-beta@f4452e031aed [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersstandard8
bugs1558517
milestone69.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1558517 - Pre 3.2: Disable conflicting eslint:recommended rules by extending eslint-config-prettier, r=standard8 Differential Revision: https://phabricator.services.mozilla.com/D34536
tools/lint/eslint/eslint-plugin-mozilla/lib/configs/recommended.js
--- a/tools/lint/eslint/eslint-plugin-mozilla/lib/configs/recommended.js
+++ b/tools/lint/eslint/eslint-plugin-mozilla/lib/configs/recommended.js
@@ -11,16 +11,17 @@ module.exports = {
   "env": {
     "browser": true,
     "es6": true,
     "mozilla/privileged": true,
   },
 
   "extends": [
     "eslint:recommended",
+    "plugin:prettier/recommended",
   ],
 
   "globals": {
     "Cc": false,
     // Specific to Firefox (Chrome code only).
     "ChromeUtils": false,
     "Ci": false,
     "Components": false,
@@ -77,17 +78,16 @@ module.exports = {
     "ecmaVersion": 9,
   },
 
   // When adding items to this file please check for effects on sub-directories.
   "plugins": [
     "html",
     "fetch-options",
     "no-unsanitized",
-    "prettier",
   ],
 
   // When adding items to this file please check for effects on all of toolkit
   // and browser
   "rules": {
     // Warn about cyclomatic complexity in functions.
     // XXX Get this down to 20?
     "complexity": ["error", 34],
@@ -261,19 +261,16 @@ module.exports = {
     "no-useless-return": "error",
 
     // No using with
     "no-with": "error",
 
     // Require object-literal shorthand with ES6 method syntax
     "object-shorthand": ["error", "always", { "avoidQuotes": true }],
 
-    // Formatting.
-    "prettier/prettier": "error",
-
     // XXX Bug 1487642 - decide if we want to enable this or not.
     // Require generator functions to contain yield
     "require-yield": "off",
   },
 
   // To avoid bad interactions of the html plugin with the xml preprocessor in
   // eslint-plugin-mozilla, we turn off processing of the html plugin for .xml
   // files.