Skip to content

Commit

Permalink
tools: enable es2022 env in ESLint config
Browse files Browse the repository at this point in the history
This adds more globals to the set known by ESLint.

PR-URL: #42043
Reviewed-By: Mestery <[email protected]>
Reviewed-By: Antoine du Hamel <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Benjamin Gruenbaum <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Darshan Sen <[email protected]>
  • Loading branch information
targos authored and bengl committed Feb 22, 2022
1 parent fea682c commit 6742625
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
6 changes: 3 additions & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ Module._findPath = (request, paths, isMain) => {

module.exports = {
root: true,
env: {
es2022: true,
},
extends: ['eslint:recommended', 'plugin:jsdoc/recommended'],
plugins: ['jsdoc', 'markdown', 'node-core'],
parser: '@babel/eslint-parser',
Expand Down Expand Up @@ -314,13 +317,10 @@ module.exports = {
'node-core/no-duplicate-requires': 'error',
},
globals: {
Atomics: 'readable',
BigInt: 'readable',
Crypto: 'readable',
CryptoKey: 'readable',
fetch: 'readable',
FormData: 'readable',
globalThis: 'readable',
Response: 'readable',
SubtleCrypto: 'readable',
},
Expand Down
5 changes: 0 additions & 5 deletions test/.eslintrc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,3 @@ rules:
# Global scoped methods and vars
globals:
WebAssembly: false
BigInt: false
BigInt64Array: false
BigUint64Array: false
SharedArrayBuffer: false
globalThis: false

0 comments on commit 6742625

Please sign in to comment.