Bug 1440094 - Allow `console` as a global for eslint;r=Mossop draft
authorBrian Grinstead <bgrinstead@mozilla.com>
Tue, 27 Feb 2018 11:29:35 -0800
changeset 760497 b139cc99ac557eafdb307eb05d74a9e6380df37a
parent 760371 b184be59874080e96903183176c0f88dcbfafe25
child 760498 d97cb7e9c6a3fe657598672a0a415a9a233784a9
push id100672
push userbgrinstead@mozilla.com
push dateTue, 27 Feb 2018 19:35:32 +0000
reviewersMossop
bugs1440094, 1425463
milestone60.0a1
Bug 1440094 - Allow `console` as a global for eslint;r=Mossop As of Bug 1425463 it's available in all contexts (including JSM). The following patche is going to remove imports to Console.jsm, so prepare for this by allowing it to be used as a global in eslint. MozReview-Commit-ID: 3gCIspnlVgB
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
@@ -45,16 +45,17 @@ module.exports = {
     "StopIteration": false,
     "StructuredCloneHolder": false,
     "WebAssembly": false,
     "WebExtensionContentScript": false,
     "WebExtensionPolicy": false,
     "WebrtcGlobalInformation": false,
     // Non-standard, specific to Firefox.
     "XULElement": false,
+    "console": true,
     "dump": true,
     "openDialog": false,
     "sizeToContent": false,
     // Specific to Firefox
     // eslint-disable-next-line max-len
     // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/uneval
     "uneval": false
   },