diff --git a/.eslintrc.js b/eslint.config.js
similarity index 78%
rename from .eslintrc.js
rename to eslint.config.js
index 74e7ab5ad52c..03e4fc93d697 100644
--- a/.eslintrc.js
+++ b/eslint.config.js
@@ -1,7 +1,22 @@
'use strict';
-const RESTRICTED_GLOBALS = require('confusing-browser-globals');
-const SUPPORTED_NODE_VERSIONS = require('core-js-builder/package').engines.node;
+const globals = require('globals');
+const confusingBrowserGlobals = require('confusing-browser-globals');
+const parserJSONC = require('jsonc-eslint-parser');
+const pluginArrayFunc = require('eslint-plugin-array-func');
+const pluginESX = require('eslint-plugin-es-x');
+const pluginESlintComments = require('eslint-plugin-eslint-comments');
+const pluginImport = require('eslint-plugin-import');
+const pluginJSONC = require('eslint-plugin-jsonc');
+const pluginN = require('eslint-plugin-n');
+const pluginPromise = require('eslint-plugin-promise');
+const pluginQUnit = require('eslint-plugin-qunit');
+const pluginRegExp = require('eslint-plugin-regexp');
+const pluginSonarJS = require('eslint-plugin-sonarjs');
+const pluginUnicorn = require('eslint-plugin-unicorn');
+
+const PACKAGES_NODE_VERSIONS = require('core-js-builder/package').engines.node;
const DEV_NODE_VERSIONS = '^16.13';
+
const ERROR = 'error';
const OFF = 'off';
const ALWAYS = 'always';
@@ -9,10 +24,7 @@ const NEVER = 'never';
const READONLY = 'readonly';
function disable(rules) {
- return Object.keys(rules).reduce((memo, rule) => {
- memo[rule] = OFF;
- return memo;
- }, {});
+ return Object.fromEntries(Object.keys(rules).map(key => [key, OFF]));
}
const base = {
@@ -51,14 +63,12 @@ const base = {
'no-func-assign': ERROR,
// disallow irregular whitespace outside of strings and comments
'no-irregular-whitespace': ERROR,
- // disallow literal numbers that lose precision
- // 'no-loss-of-precision': ERROR, // TODO
// disallow the use of object properties of the global object (Math and JSON) as functions
'no-obj-calls': ERROR,
// disallow use of Object.prototypes builtins directly
'no-prototype-builtins': ERROR,
// disallow specific global variables
- 'no-restricted-globals': [ERROR, ...RESTRICTED_GLOBALS],
+ 'no-restricted-globals': [ERROR, ...confusingBrowserGlobals],
// disallow returning values from setters
'no-setter-return': ERROR,
// disallow sparse arrays
@@ -144,7 +154,7 @@ const base = {
// disallow usage of __proto__ property
'no-proto': ERROR,
// disallow declaring the same variable more then once
- 'no-redeclare': ERROR,
+ 'no-redeclare': [ERROR, { builtinGlobals: false }],
// disallow unnecessary calls to `.call()` and `.apply()`
'no-useless-call': ERROR,
// disallow redundant return statements
@@ -194,7 +204,11 @@ const base = {
// disallow initializing variables to undefined
'no-undef-init': ERROR,
// disallow declaration of variables that are not used in the code
- 'no-unused-vars': [ERROR, { vars: 'local', args: 'after-used', ignoreRestSiblings: true }],
+ 'no-unused-vars': [ERROR, {
+ vars: 'local',
+ args: 'after-used',
+ ignoreRestSiblings: true,
+ }],
// stylistic issues:
// enforce spacing inside array brackets
@@ -229,6 +243,8 @@ const base = {
'key-spacing': [ERROR, { beforeColon: false, afterColon: true }],
// enforce consistent linebreak style
'linebreak-style': [ERROR, 'unix'],
+ // require logical assignment operator shorthand
+ 'logical-assignment-operators': [ERROR, ALWAYS],
// specify the maximum length of a line in your program
'max-len': [ERROR, {
code: 140,
@@ -290,7 +306,10 @@ const base = {
// require or disallow spaces before/after unary operators
'space-unary-ops': ERROR,
// require or disallow a space immediately following the // or /* in a comment
- 'spaced-comment': [ERROR, ALWAYS, { line: { exceptions: ['/'] }, block: { exceptions: ['*'] } }],
+ 'spaced-comment': [ERROR, ALWAYS, {
+ line: { exceptions: ['/'] },
+ block: { exceptions: ['*'] },
+ }],
// enforce spacing around colons of switch statements
'switch-colon-spacing': ERROR,
// require or disallow the Unicode Byte Order Mark
@@ -322,27 +341,27 @@ const base = {
// node:
// disallow deprecated APIs
- 'n/no-deprecated-api': ERROR,
+ 'node/no-deprecated-api': ERROR,
// require require() calls to be placed at top-level module scope
- 'n/global-require': ERROR,
+ 'node/global-require': ERROR,
// disallow the assignment to `exports`
- 'n/no-exports-assign': ERROR,
+ 'node/no-exports-assign': ERROR,
// disallow require calls to be mixed with regular variable declarations
- 'n/no-mixed-requires': [ERROR, { grouping: true, allowCall: false }],
+ 'node/no-mixed-requires': [ERROR, { grouping: true, allowCall: false }],
// disallow new operators with calls to require
- 'n/no-new-require': ERROR,
+ 'node/no-new-require': ERROR,
// disallow string concatenation with `__dirname` and `__filename`
- 'n/no-path-concat': ERROR,
+ 'node/no-path-concat': ERROR,
// disallow the use of `process.exit()`
- 'n/no-process-exit': ERROR,
+ 'node/no-process-exit': ERROR,
// prefer global
- 'n/prefer-global/buffer': [ERROR, ALWAYS],
- 'n/prefer-global/console': [ERROR, ALWAYS],
- 'n/prefer-global/process': [ERROR, ALWAYS],
- 'n/prefer-global/text-decoder': [ERROR, ALWAYS],
- 'n/prefer-global/text-encoder': [ERROR, ALWAYS],
- 'n/prefer-global/url-search-params': [ERROR, ALWAYS],
- 'n/prefer-global/url': [ERROR, ALWAYS],
+ 'node/prefer-global/buffer': [ERROR, ALWAYS],
+ 'node/prefer-global/console': [ERROR, ALWAYS],
+ 'node/prefer-global/process': [ERROR, ALWAYS],
+ 'node/prefer-global/text-decoder': [ERROR, ALWAYS],
+ 'node/prefer-global/text-encoder': [ERROR, ALWAYS],
+ 'node/prefer-global/url-search-params': [ERROR, ALWAYS],
+ 'node/prefer-global/url': [ERROR, ALWAYS],
// es6+:
// require parentheses around arrow function arguments
@@ -464,8 +483,6 @@ const base = {
'unicorn/prefer-array-index-of': ERROR,
// prefer `.some(…)` over `.filter(…).length` check and `.find(…)`
'unicorn/prefer-array-some': ERROR,
- // prefer code points over char codes
- 'unicorn/prefer-code-point': ERROR,
// prefer default parameters over reassignment
'unicorn/prefer-default-parameters': ERROR,
// prefer `EventTarget` over `EventEmitter`
@@ -663,19 +680,19 @@ const base = {
'regexp/use-ignore-case': ERROR,
// disallow function declarations in if statement clauses without using blocks
- 'es-x/no-function-declarations-in-if-statement-clauses-without-block': ERROR,
+ 'es/no-function-declarations-in-if-statement-clauses-without-block': ERROR,
// disallow initializers in for-in heads
- 'es-x/no-initializers-in-for-in': ERROR,
+ 'es/no-initializers-in-for-in': ERROR,
// disallow \u2028 and \u2029 in string literals
- 'es-x/no-json-superset': ERROR,
+ 'es/no-json-superset': ERROR,
// disallow labelled function declarations
- 'es-x/no-labelled-function-declarations': ERROR,
+ 'es/no-labelled-function-declarations': ERROR,
// disallow the `RegExp.prototype.compile` method
- 'es-x/no-regexp-prototype-compile': ERROR,
+ 'es/no-regexp-prototype-compile': ERROR,
// disallow identifiers from shadowing catch parameter names
- 'es-x/no-shadow-catch-param': ERROR,
+ 'es/no-shadow-catch-param': ERROR,
- // eslint-comments
+ // eslint-comments:
// require include descriptions in eslint directive-comments
'eslint-comments/require-description': ERROR,
};
@@ -685,6 +702,8 @@ const es3 = {
'comma-dangle': [ERROR, NEVER],
// encourages use of dot notation whenever possible
'dot-notation': [ERROR, { allowKeywords: false }],
+ // disallow logical assignment operator shorthand
+ 'logical-assignment-operators': [ERROR, NEVER],
// disallow function or variable declarations in nested blocks
'no-inner-declarations': ERROR,
// require let or const instead of var
@@ -707,8 +726,6 @@ const es3 = {
'quote-props': [ERROR, 'as-needed', { keywords: true }],
// require strict mode directives
strict: OFF,
- // prefer code points over char codes
- 'unicorn/prefer-code-point': OFF,
// prefer default parameters over reassignment
'unicorn/prefer-default-parameters': OFF,
// prefer using a logical operator over a ternary
@@ -716,151 +733,151 @@ const es3 = {
};
const forbidESAnnexBBuiltIns = {
- 'es-x/no-date-prototype-getyear-setyear': ERROR,
- 'es-x/no-date-prototype-togmtstring': ERROR,
- 'es-x/no-escape-unescape': ERROR,
- 'es-x/no-legacy-object-prototype-accessor-methods': ERROR,
- 'es-x/no-string-create-html-methods': ERROR,
- 'es-x/no-string-prototype-substr': ERROR,
- 'es-x/no-string-prototype-trimleft-trimright': ERROR,
+ 'es/no-date-prototype-getyear-setyear': ERROR,
+ 'es/no-date-prototype-togmtstring': ERROR,
+ 'es/no-escape-unescape': ERROR,
+ 'es/no-legacy-object-prototype-accessor-methods': ERROR,
+ 'es/no-string-create-html-methods': ERROR,
+ 'es/no-string-prototype-substr': ERROR,
+ 'es/no-string-prototype-trimleft-trimright': ERROR,
};
const forbidES5BuiltIns = {
- 'es-x/no-array-isarray': ERROR,
- 'es-x/no-array-prototype-every': ERROR,
- 'es-x/no-array-prototype-filter': ERROR,
- 'es-x/no-array-prototype-foreach': ERROR,
- 'es-x/no-array-prototype-indexof': ERROR,
- 'es-x/no-array-prototype-lastindexof': ERROR,
- 'es-x/no-array-prototype-map': ERROR,
- 'es-x/no-array-prototype-reduce': ERROR,
- 'es-x/no-array-prototype-reduceright': ERROR,
- 'es-x/no-array-prototype-some': ERROR,
- 'es-x/no-date-now': ERROR,
- 'es-x/no-function-prototype-bind': ERROR,
- 'es-x/no-json': ERROR,
- 'es-x/no-object-create': ERROR,
- 'es-x/no-object-defineproperties': ERROR,
- 'es-x/no-object-defineproperty': ERROR,
- 'es-x/no-object-freeze': ERROR,
- 'es-x/no-object-getownpropertydescriptor': ERROR,
- 'es-x/no-object-getownpropertynames': ERROR,
- 'es-x/no-object-getprototypeof': ERROR,
- 'es-x/no-object-isextensible': ERROR,
- 'es-x/no-object-isfrozen': ERROR,
- 'es-x/no-object-issealed': ERROR,
- 'es-x/no-object-keys': ERROR,
- 'es-x/no-object-preventextensions': ERROR,
- 'es-x/no-object-seal': ERROR,
- 'es-x/no-string-prototype-trim': ERROR,
+ 'es/no-array-isarray': ERROR,
+ 'es/no-array-prototype-every': ERROR,
+ 'es/no-array-prototype-filter': ERROR,
+ 'es/no-array-prototype-foreach': ERROR,
+ 'es/no-array-prototype-indexof': ERROR,
+ 'es/no-array-prototype-lastindexof': ERROR,
+ 'es/no-array-prototype-map': ERROR,
+ 'es/no-array-prototype-reduce': ERROR,
+ 'es/no-array-prototype-reduceright': ERROR,
+ 'es/no-array-prototype-some': ERROR,
+ 'es/no-date-now': ERROR,
+ 'es/no-function-prototype-bind': ERROR,
+ 'es/no-json': ERROR,
+ 'es/no-object-create': ERROR,
+ 'es/no-object-defineproperties': ERROR,
+ 'es/no-object-defineproperty': ERROR,
+ 'es/no-object-freeze': ERROR,
+ 'es/no-object-getownpropertydescriptor': ERROR,
+ 'es/no-object-getownpropertynames': ERROR,
+ 'es/no-object-getprototypeof': ERROR,
+ 'es/no-object-isextensible': ERROR,
+ 'es/no-object-isfrozen': ERROR,
+ 'es/no-object-issealed': ERROR,
+ 'es/no-object-keys': ERROR,
+ 'es/no-object-preventextensions': ERROR,
+ 'es/no-object-seal': ERROR,
+ 'es/no-string-prototype-trim': ERROR,
};
const forbidES2015BuiltIns = {
- 'es-x/no-array-from': ERROR,
- 'es-x/no-array-of': ERROR,
- 'es-x/no-array-prototype-copywithin': ERROR,
- 'es-x/no-array-prototype-entries': ERROR,
- 'es-x/no-array-prototype-fill': ERROR,
- 'es-x/no-array-prototype-find': ERROR,
- 'es-x/no-array-prototype-findindex': ERROR,
- 'es-x/no-array-prototype-keys': ERROR,
- 'es-x/no-array-prototype-values': ERROR,
- 'es-x/no-map': ERROR,
- 'es-x/no-math-acosh': ERROR,
- 'es-x/no-math-asinh': ERROR,
- 'es-x/no-math-atanh': ERROR,
- 'es-x/no-math-cbrt': ERROR,
- 'es-x/no-math-clz32': ERROR,
- 'es-x/no-math-cosh': ERROR,
- 'es-x/no-math-expm1': ERROR,
- 'es-x/no-math-fround': ERROR,
- 'es-x/no-math-hypot': ERROR,
- 'es-x/no-math-imul': ERROR,
- 'es-x/no-math-log10': ERROR,
- 'es-x/no-math-log1p': ERROR,
- 'es-x/no-math-log2': ERROR,
- 'es-x/no-math-sign': ERROR,
- 'es-x/no-math-sinh': ERROR,
- 'es-x/no-math-tanh': ERROR,
- 'es-x/no-math-trunc': ERROR,
- 'es-x/no-number-epsilon': ERROR,
- 'es-x/no-number-isfinite': ERROR,
- 'es-x/no-number-isinteger': ERROR,
- 'es-x/no-number-isnan': ERROR,
- 'es-x/no-number-issafeinteger': ERROR,
- 'es-x/no-number-maxsafeinteger': ERROR,
- 'es-x/no-number-minsafeinteger': ERROR,
- 'es-x/no-number-parsefloat': ERROR,
- 'es-x/no-number-parseint': ERROR,
- 'es-x/no-object-assign': ERROR,
- 'es-x/no-object-getownpropertysymbols': ERROR,
- 'es-x/no-object-is': ERROR,
- 'es-x/no-object-setprototypeof': ERROR,
- 'es-x/no-promise': ERROR,
- 'es-x/no-proxy': ERROR,
- 'es-x/no-reflect': ERROR,
- 'es-x/no-regexp-prototype-flags': ERROR,
- 'es-x/no-set': ERROR,
- 'es-x/no-string-fromcodepoint': ERROR,
- 'es-x/no-string-prototype-codepointat': ERROR,
- 'es-x/no-string-prototype-endswith': ERROR,
- 'es-x/no-string-prototype-includes': ERROR,
- 'es-x/no-string-prototype-normalize': ERROR,
- 'es-x/no-string-prototype-repeat': ERROR,
- 'es-x/no-string-prototype-startswith': ERROR,
- 'es-x/no-string-raw': ERROR,
- 'es-x/no-symbol': ERROR,
- 'es-x/no-typed-arrays': ERROR,
- 'es-x/no-weak-map': ERROR,
- 'es-x/no-weak-set': ERROR,
+ 'es/no-array-from': ERROR,
+ 'es/no-array-of': ERROR,
+ 'es/no-array-prototype-copywithin': ERROR,
+ 'es/no-array-prototype-entries': ERROR,
+ 'es/no-array-prototype-fill': ERROR,
+ 'es/no-array-prototype-find': ERROR,
+ 'es/no-array-prototype-findindex': ERROR,
+ 'es/no-array-prototype-keys': ERROR,
+ 'es/no-array-prototype-values': ERROR,
+ 'es/no-map': ERROR,
+ 'es/no-math-acosh': ERROR,
+ 'es/no-math-asinh': ERROR,
+ 'es/no-math-atanh': ERROR,
+ 'es/no-math-cbrt': ERROR,
+ 'es/no-math-clz32': ERROR,
+ 'es/no-math-cosh': ERROR,
+ 'es/no-math-expm1': ERROR,
+ 'es/no-math-fround': ERROR,
+ 'es/no-math-hypot': ERROR,
+ 'es/no-math-imul': ERROR,
+ 'es/no-math-log10': ERROR,
+ 'es/no-math-log1p': ERROR,
+ 'es/no-math-log2': ERROR,
+ 'es/no-math-sign': ERROR,
+ 'es/no-math-sinh': ERROR,
+ 'es/no-math-tanh': ERROR,
+ 'es/no-math-trunc': ERROR,
+ 'es/no-number-epsilon': ERROR,
+ 'es/no-number-isfinite': ERROR,
+ 'es/no-number-isinteger': ERROR,
+ 'es/no-number-isnan': ERROR,
+ 'es/no-number-issafeinteger': ERROR,
+ 'es/no-number-maxsafeinteger': ERROR,
+ 'es/no-number-minsafeinteger': ERROR,
+ 'es/no-number-parsefloat': ERROR,
+ 'es/no-number-parseint': ERROR,
+ 'es/no-object-assign': ERROR,
+ 'es/no-object-getownpropertysymbols': ERROR,
+ 'es/no-object-is': ERROR,
+ 'es/no-object-setprototypeof': ERROR,
+ 'es/no-promise': ERROR,
+ 'es/no-proxy': ERROR,
+ 'es/no-reflect': ERROR,
+ 'es/no-regexp-prototype-flags': ERROR,
+ 'es/no-set': ERROR,
+ 'es/no-string-fromcodepoint': ERROR,
+ 'es/no-string-prototype-codepointat': ERROR,
+ 'es/no-string-prototype-endswith': ERROR,
+ 'es/no-string-prototype-includes': ERROR,
+ 'es/no-string-prototype-normalize': ERROR,
+ 'es/no-string-prototype-repeat': ERROR,
+ 'es/no-string-prototype-startswith': ERROR,
+ 'es/no-string-raw': ERROR,
+ 'es/no-symbol': ERROR,
+ 'es/no-typed-arrays': ERROR,
+ 'es/no-weak-map': ERROR,
+ 'es/no-weak-set': ERROR,
};
const forbidES2016BuiltIns = {
- 'es-x/no-array-prototype-includes': ERROR,
+ 'es/no-array-prototype-includes': ERROR,
};
const forbidES2017BuiltIns = {
- 'es-x/no-atomics': ERROR,
- 'es-x/no-object-entries': ERROR,
- 'es-x/no-object-getownpropertydescriptors': ERROR,
- 'es-x/no-object-values': ERROR,
- 'es-x/no-shared-array-buffer': ERROR,
- 'es-x/no-string-prototype-padstart-padend': ERROR,
+ 'es/no-atomics': ERROR,
+ 'es/no-object-entries': ERROR,
+ 'es/no-object-getownpropertydescriptors': ERROR,
+ 'es/no-object-values': ERROR,
+ 'es/no-shared-array-buffer': ERROR,
+ 'es/no-string-prototype-padstart-padend': ERROR,
};
const forbidES2018BuiltIns = {
- 'es-x/no-promise-prototype-finally': ERROR,
+ 'es/no-promise-prototype-finally': ERROR,
};
const forbidES2019BuiltIns = {
'unicorn/prefer-array-flat': OFF,
- 'es-x/no-array-prototype-flat': ERROR,
- 'es-x/no-object-fromentries': ERROR,
- 'es-x/no-string-prototype-trimstart-trimend': ERROR,
- 'es-x/no-symbol-prototype-description': ERROR,
+ 'es/no-array-prototype-flat': ERROR,
+ 'es/no-object-fromentries': ERROR,
+ 'es/no-string-prototype-trimstart-trimend': ERROR,
+ 'es/no-symbol-prototype-description': ERROR,
};
const forbidES2020BuiltIns = {
- 'es-x/no-bigint': ERROR,
- 'es-x/no-global-this': ERROR,
- 'es-x/no-promise-all-settled': ERROR,
- 'es-x/no-string-prototype-matchall': ERROR,
+ 'es/no-bigint': ERROR,
+ 'es/no-global-this': ERROR,
+ 'es/no-promise-all-settled': ERROR,
+ 'es/no-string-prototype-matchall': ERROR,
};
const forbidES2021BuiltIns = {
- 'es-x/no-promise-any': ERROR,
- 'es-x/no-string-prototype-replaceall': ERROR,
- 'es-x/no-weakrefs': ERROR,
+ 'es/no-promise-any': ERROR,
+ 'es/no-string-prototype-replaceall': ERROR,
+ 'es/no-weakrefs': ERROR,
};
const forbidES2022BuiltIns = {
- 'es-x/no-array-string-prototype-at': ERROR,
- 'es-x/no-object-hasown': ERROR,
- 'es-x/no-regexp-d-flag': ERROR,
+ 'es/no-array-string-prototype-at': ERROR,
+ 'es/no-object-hasown': ERROR,
+ 'es/no-regexp-d-flag': ERROR,
};
const forbidES2023BuiltIns = {
- 'es-x/no-array-prototype-findlast-findlastindex': ERROR,
+ 'es/no-array-prototype-findlast-findlastindex': ERROR,
};
const forbidModernESBuiltIns = {
@@ -891,41 +908,41 @@ const polyfills = {
const transpiledAndPolyfilled = {
// disallow accessor properties
- 'es-x/no-accessor-properties': ERROR,
+ 'es/no-accessor-properties': ERROR,
// disallow async functions
- 'es-x/no-async-functions': ERROR,
+ 'es/no-async-functions': ERROR,
// disallow async iteration
- 'es-x/no-async-iteration': ERROR,
+ 'es/no-async-iteration': ERROR,
// disallow generators
- 'es-x/no-generators': ERROR,
+ 'es/no-generators': ERROR,
// disallow top-level `await`
- 'es-x/no-top-level-await': ERROR,
+ 'es/no-top-level-await': ERROR,
// unpolyfillable es2015 builtins
- 'es-x/no-proxy': ERROR,
- 'es-x/no-string-prototype-normalize': ERROR,
+ 'es/no-proxy': ERROR,
+ 'es/no-string-prototype-normalize': ERROR,
// unpolyfillable es2017 builtins
- 'es-x/no-atomics': ERROR,
- 'es-x/no-shared-array-buffer': ERROR,
+ 'es/no-atomics': ERROR,
+ 'es/no-shared-array-buffer': ERROR,
// unpolyfillable es2020 builtins
- 'es-x/no-bigint': ERROR,
+ 'es/no-bigint': ERROR,
// unpolyfillable es2021 builtins
- 'es-x/no-weakrefs': ERROR,
- // prefer code points over char codes
- 'unicorn/prefer-code-point': OFF,
+ 'es/no-weakrefs': ERROR,
};
const nodePackages = {
...asyncAwait,
+ // disallow logical assignment operator shorthand
+ 'logical-assignment-operators': [ERROR, NEVER],
// enforces the use of `catch()` on un-returned promises
'promise/catch-or-return': ERROR,
// disallow unsupported ECMAScript built-ins on the specified version
- 'n/no-unsupported-features/node-builtins': [ERROR, { version: SUPPORTED_NODE_VERSIONS }],
+ 'node/no-unsupported-features/node-builtins': [ERROR, { version: PACKAGES_NODE_VERSIONS }],
...disable(forbidES5BuiltIns),
...disable(forbidES2015BuiltIns),
...disable(forbidES2016BuiltIns),
...disable(forbidES2017BuiltIns),
- 'es-x/no-atomics': ERROR,
- 'es-x/no-shared-array-buffer': ERROR,
+ 'es/no-atomics': ERROR,
+ 'es/no-shared-array-buffer': ERROR,
...forbidES2018BuiltIns,
...forbidES2019BuiltIns,
...forbidES2020BuiltIns,
@@ -937,9 +954,9 @@ const nodePackages = {
const nodeDev = {
...asyncAwait,
// disallow unsupported ECMAScript built-ins on the specified version
- 'n/no-unsupported-features/node-builtins': [ERROR, { version: DEV_NODE_VERSIONS }],
+ 'node/no-unsupported-features/node-builtins': [ERROR, { version: DEV_NODE_VERSIONS }],
...disable(forbidModernESBuiltIns),
- 'es-x/no-array-string-prototype-at': ERROR,
+ 'es/no-array-string-prototype-at': ERROR,
...forbidES2023BuiltIns,
};
@@ -1095,193 +1112,176 @@ const json = {
strict: OFF,
};
-module.exports = {
- root: true,
- parserOptions: {
- ecmaVersion: 'latest',
- sourceType: 'script',
- },
- env: {
- // unnecessary global builtins disabled by related rules
- es2022: true,
- browser: true,
- node: true,
- worker: true,
- },
- plugins: [
- 'array-func',
- 'es-x',
- 'eslint-comments',
- 'import',
- 'jsonc',
- 'n',
- 'promise',
- 'qunit',
- 'regexp',
- 'sonarjs',
- 'unicorn',
- ],
- reportUnusedDisableDirectives: true,
- rules: {
- ...base,
- ...forbidESAnnexBBuiltIns,
- },
- overrides: [
- {
- files: [
- 'packages/core-js/**',
- 'packages/core-js-pure/**',
- 'tests/compat/**.js',
- 'tests/worker/**',
- ],
- parserOptions: {
- ecmaVersion: 3,
+const globalsESNext = {
+ AsyncIterator: READONLY,
+ Iterator: READONLY,
+ Observable: READONLY,
+ compositeKey: READONLY,
+ compositeSymbol: READONLY,
+};
+
+const globalsZX = {
+ $: READONLY,
+ __dirname: READONLY,
+ __filename: READONLY,
+ argv: READONLY,
+ cd: READONLY,
+ chalk: READONLY,
+ echo: READONLY,
+ fetch: READONLY,
+ fs: READONLY,
+ glob: READONLY,
+ nothrow: READONLY,
+ os: READONLY,
+ path: READONLY,
+ question: READONLY,
+ require: READONLY,
+ sleep: READONLY,
+ stdin: READONLY,
+ which: READONLY,
+ within: READONLY,
+ YAML: READONLY,
+};
+
+module.exports = [
+ {
+ languageOptions: {
+ ecmaVersion: 'latest',
+ sourceType: 'script',
+ // unnecessary global builtins disabled by related rules
+ globals: {
+ ...globals.builtin,
+ ...globals.browser,
+ ...globals.node,
+ ...globals.worker,
},
- rules: es3,
- },
- {
- files: [
- 'packages/core-js/**',
- 'packages/core-js-pure/**',
- 'tests/pure/**',
- 'tests/worker/**',
- ],
- rules: forbidModernESBuiltIns,
},
- {
- files: [
- 'packages/core-js/**',
- 'packages/core-js-pure/**',
- ],
- rules: polyfills,
+ linterOptions: {
+ reportUnusedDisableDirectives: true,
},
- {
- files: [
- 'packages/core-js/postinstall.js',
- 'packages/core-js-pure/postinstall.js',
- ],
- rules: disable(forbidES5BuiltIns),
- },
- {
- files: [
- 'tests/helpers/**',
- 'tests/pure/**',
- 'tests/tests/**',
- 'tests/wpt-url-resources/**',
- ],
- parserOptions: {
- sourceType: 'module',
- },
- rules: transpiledAndPolyfilled,
+ plugins: {
+ 'array-func': pluginArrayFunc,
+ es: pluginESX,
+ 'eslint-comments': pluginESlintComments,
+ import: pluginImport,
+ jsonc: pluginJSONC,
+ node: pluginN,
+ promise: pluginPromise,
+ qunit: pluginQUnit,
+ regexp: pluginRegExp,
+ sonarjs: pluginSonarJS,
+ unicorn: pluginUnicorn,
},
- {
- files: [
- 'tests/compat/**',
- 'tests/helpers/**',
- 'tests/observables/**',
- 'tests/promises-aplus/**',
- 'tests/pure/**',
- 'tests/tests/**',
- 'tests/worker/**',
- 'tests/wpt-url-resources/**',
- 'tests/commonjs.js',
- 'tests/commonjs-entries-content.js',
- 'tests/targets-parser.js',
- ],
- rules: tests,
+ rules: {
+ ...base,
+ ...forbidESAnnexBBuiltIns,
},
- {
- files: [
- 'tests/helpers/**',
- 'tests/pure/**',
- 'tests/tests/**',
- ],
- env: {
- qunit: true,
- },
- rules: qunit,
+ },
+ {
+ files: [
+ '**/*.mjs',
+ ],
+ languageOptions: {
+ sourceType: 'module',
},
- {
- files: [
- 'packages/core-js-builder/**',
- 'packages/core-js-compat/**',
- ],
- rules: nodePackages,
+ },
+ {
+ files: [
+ 'packages/core-js?(-pure)/**',
+ 'tests/@(compat|worker)/*.js',
+ ],
+ languageOptions: {
+ ecmaVersion: 3,
},
- {
- files: [
- 'packages/core-js-compat/src/**',
- 'scripts/**',
- 'tests/compat/deno-runner.mjs',
- 'tests/observables/**',
- 'tests/promises-aplus/**',
- 'tests/commonjs.js',
- 'tests/commonjs-entries-content.js',
- 'tests/targets-parser.js',
- '.eslintrc.js',
- '.webpack.config.js',
- 'babel.config.js',
- ],
- rules: nodeDev,
+ rules: es3,
+ },
+ {
+ files: [
+ 'packages/core-js?(-pure)/**',
+ 'tests/@(pure|worker)/**',
+ ],
+ rules: forbidModernESBuiltIns,
+ },
+ {
+ files: [
+ 'packages/core-js?(-pure)/**',
+ ],
+ rules: polyfills,
+ },
+ {
+ files: [
+ '**/postinstall.js',
+ ],
+ rules: disable(forbidES5BuiltIns),
+ },
+ {
+ files: [
+ 'tests/@(helpers|pure|tests|wpt-url-resources)/**',
+ ],
+ languageOptions: {
+ sourceType: 'module',
},
- {
- files: [
- 'tests/observables/**',
- 'tests/tests/**',
- 'tests/compat/**',
- ],
- globals: {
- AsyncIterator: READONLY,
- Iterator: READONLY,
- Observable: READONLY,
- compositeKey: READONLY,
- compositeSymbol: READONLY,
- },
+ rules: transpiledAndPolyfilled,
+ },
+ {
+ files: [
+ 'tests/**',
+ ],
+ rules: tests,
+ },
+ {
+ files: [
+ 'tests/@(helpers|pure|tests)/**',
+ ],
+ languageOptions: {
+ globals: globals.qunit,
},
- {
- files: ['**/*.mjs'],
- parserOptions: {
- ecmaVersion: 'latest',
- sourceType: 'module',
- },
+ rules: qunit,
+ },
+ {
+ files: [
+ 'packages/core-js-@(builder|compat)/**',
+ ],
+ rules: nodePackages,
+ },
+ {
+ files: [
+ '*.js',
+ 'packages/core-js-compat/src/**',
+ 'scripts/**',
+ 'tests/?(compat/)*.mjs',
+ 'tests/@(compat-tools|observables|promises-aplus)/**',
+ ],
+ rules: nodeDev,
+ },
+ {
+ files: [
+ 'tests/@(observables|tests|compat)/**',
+ ],
+ languageOptions: {
+ globals: globalsESNext,
},
- {
- files: [
- 'scripts/**',
- 'tests/**/*.mjs',
- ],
+ },
+ {
+ files: [
+ 'packages/core-js-compat/src/**',
+ 'scripts/**',
+ 'tests/**/*.mjs',
+ ],
+ languageOptions: {
// zx
- globals: {
- $: READONLY,
- __dirname: READONLY,
- __filename: READONLY,
- argv: READONLY,
- cd: READONLY,
- chalk: READONLY,
- echo: READONLY,
- fetch: READONLY,
- fs: READONLY,
- glob: READONLY,
- nothrow: READONLY,
- os: READONLY,
- path: READONLY,
- question: READONLY,
- require: READONLY,
- sleep: READONLY,
- stdin: READONLY,
- which: READONLY,
- within: READONLY,
- YAML: READONLY,
- },
- rules: {
- // allow use of console
- 'no-console': OFF,
- },
+ globals: globalsZX,
},
- {
- files: ['**/*.json'],
- parser: 'jsonc-eslint-parser',
- rules: json,
+ rules: {
+ // allow use of console
+ 'no-console': OFF,
},
- ],
-};
+ },
+ {
+ files: ['**/*.json'],
+ languageOptions: {
+ parser: parserJSONC,
+ },
+ rules: json,
+ },
+];
diff --git a/package.json b/package.json
index ffdd8d0f8b62..ae7f364495d3 100644
--- a/package.json
+++ b/package.json
@@ -41,7 +41,7 @@
"confusing-browser-globals": "^1.0.11",
"david": "^12.0.0",
"es-observable": "git+https://github.com/tc39/proposal-observable.git#d3404f06bc70c7c578a5047dfb3dc813730e3319",
- "eslint": "^8.23.1",
+ "eslint": "^8.24.0",
"eslint-plugin-array-func": "^3.1.7",
"eslint-plugin-es-x": "^5.3.1",
"eslint-plugin-eslint-comments": "^3.2.0",
@@ -53,6 +53,7 @@
"eslint-plugin-regexp": "^1.9.0",
"eslint-plugin-sonarjs": "~0.15.0",
"eslint-plugin-unicorn": "^43.0.2",
+ "globals": "^13.17.0",
"jsonc-eslint-parser": "^2.1.0",
"jszip": "^3.10.1",
"karma": "^6.4.1",
@@ -113,7 +114,7 @@
"copy-compat-table": "zx scripts/copy-compat-table.mjs",
"generate-indexes": "zx scripts/generate-indexes.mjs",
"lint": "run-s init test-lint",
- "test-lint": "eslint --ext .js,.mjs,.json ./",
+ "test-lint": "eslint ./",
"test-unit": "run-s test-unit-karma test-unit-node",
"test-unit-global": "karma start -f=packages/core-js-bundle/index.js,tests/bundles/tests.js",
"test-unit-global-standalone": "run-s init bundle-package bundle-helpers bundle-tests-global test-unit-global",
diff --git a/packages/core-js-compat/helpers.js b/packages/core-js-compat/helpers.js
index d7e3e4fc8557..52e9b948cdb4 100644
--- a/packages/core-js-compat/helpers.js
+++ b/packages/core-js-compat/helpers.js
@@ -1,5 +1,5 @@
'use strict';
-// eslint-disable-next-line es-x/no-object-hasown -- safe
+// eslint-disable-next-line es/no-object-hasown -- safe
const has = Object.hasOwn || Function.call.bind({}.hasOwnProperty);
function semver(input) {
diff --git a/packages/core-js/es/json/index.js b/packages/core-js/es/json/index.js
index 2576fc523c9c..5d4034777ec3 100644
--- a/packages/core-js/es/json/index.js
+++ b/packages/core-js/es/json/index.js
@@ -2,5 +2,5 @@ require('../../modules/es.json.stringify');
require('../../modules/es.json.to-string-tag');
var path = require('../../internals/path');
-// eslint-disable-next-line es-x/no-json -- safe
+// eslint-disable-next-line es/no-json -- safe
module.exports = path.JSON || (path.JSON = { stringify: JSON.stringify });
diff --git a/packages/core-js/es/json/stringify.js b/packages/core-js/es/json/stringify.js
index 016bca575a9a..5909b5982adb 100644
--- a/packages/core-js/es/json/stringify.js
+++ b/packages/core-js/es/json/stringify.js
@@ -2,7 +2,7 @@ require('../../modules/es.json.stringify');
var path = require('../../internals/path');
var apply = require('../../internals/function-apply');
-// eslint-disable-next-line es-x/no-json -- safe
+// eslint-disable-next-line es/no-json -- safe
if (!path.JSON) path.JSON = { stringify: JSON.stringify };
// eslint-disable-next-line no-unused-vars -- required for `.length`
diff --git a/packages/core-js/internals/array-buffer-basic-detection.js b/packages/core-js/internals/array-buffer-basic-detection.js
index 3012f608b726..1ee09fa86d1d 100644
--- a/packages/core-js/internals/array-buffer-basic-detection.js
+++ b/packages/core-js/internals/array-buffer-basic-detection.js
@@ -1,2 +1,2 @@
-// eslint-disable-next-line es-x/no-typed-arrays -- safe
+// eslint-disable-next-line es/no-typed-arrays -- safe
module.exports = typeof ArrayBuffer != 'undefined' && typeof DataView != 'undefined';
diff --git a/packages/core-js/internals/array-buffer-non-extensible.js b/packages/core-js/internals/array-buffer-non-extensible.js
index 7ad488a12805..b66872d3377d 100644
--- a/packages/core-js/internals/array-buffer-non-extensible.js
+++ b/packages/core-js/internals/array-buffer-non-extensible.js
@@ -4,7 +4,7 @@ var fails = require('../internals/fails');
module.exports = fails(function () {
if (typeof ArrayBuffer == 'function') {
var buffer = new ArrayBuffer(8);
- // eslint-disable-next-line es-x/no-object-isextensible, es-x/no-object-defineproperty -- safe
+ // eslint-disable-next-line es/no-object-isextensible, es/no-object-defineproperty -- safe
if (Object.isExtensible(buffer)) Object.defineProperty(buffer, 'a', { value: 8 });
}
});
diff --git a/packages/core-js/internals/array-copy-within.js b/packages/core-js/internals/array-copy-within.js
index 1bfb653761fe..e19971489305 100644
--- a/packages/core-js/internals/array-copy-within.js
+++ b/packages/core-js/internals/array-copy-within.js
@@ -8,7 +8,7 @@ var min = Math.min;
// `Array.prototype.copyWithin` method implementation
// https://tc39.es/ecma262/#sec-array.prototype.copywithin
-// eslint-disable-next-line es-x/no-array-prototype-copywithin -- safe
+// eslint-disable-next-line es/no-array-prototype-copywithin -- safe
module.exports = [].copyWithin || function copyWithin(target /* = 0 */, start /* = 0, end = @length */) {
var O = toObject(this);
var len = lengthOfArrayLike(O);
diff --git a/packages/core-js/internals/array-for-each.js b/packages/core-js/internals/array-for-each.js
index 7d9fe597eabf..22477f47ff28 100644
--- a/packages/core-js/internals/array-for-each.js
+++ b/packages/core-js/internals/array-for-each.js
@@ -8,5 +8,5 @@ var STRICT_METHOD = arrayMethodIsStrict('forEach');
// https://tc39.es/ecma262/#sec-array.prototype.foreach
module.exports = !STRICT_METHOD ? function forEach(callbackfn /* , thisArg */) {
return $forEach(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
-// eslint-disable-next-line es-x/no-array-prototype-foreach -- safe
+// eslint-disable-next-line es/no-array-prototype-foreach -- safe
} : [].forEach;
diff --git a/packages/core-js/internals/array-last-index-of.js b/packages/core-js/internals/array-last-index-of.js
index de8225d71e67..e755554191c1 100644
--- a/packages/core-js/internals/array-last-index-of.js
+++ b/packages/core-js/internals/array-last-index-of.js
@@ -1,5 +1,5 @@
'use strict';
-/* eslint-disable es-x/no-array-prototype-lastindexof -- safe */
+/* eslint-disable es/no-array-prototype-lastindexof -- safe */
var apply = require('../internals/function-apply');
var toIndexedObject = require('../internals/to-indexed-object');
var toIntegerOrInfinity = require('../internals/to-integer-or-infinity');
diff --git a/packages/core-js/internals/array-set-length.js b/packages/core-js/internals/array-set-length.js
index dd3392aded89..08523174e5da 100644
--- a/packages/core-js/internals/array-set-length.js
+++ b/packages/core-js/internals/array-set-length.js
@@ -3,7 +3,7 @@ var DESCRIPTORS = require('../internals/descriptors');
var isArray = require('../internals/is-array');
var $TypeError = TypeError;
-// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
// Safari < 13 does not throw an error in this case
@@ -11,7 +11,7 @@ var SILENT_ON_NON_WRITABLE_LENGTH_SET = DESCRIPTORS && !function () {
// makes no sense without proper strict mode support
if (this !== undefined) return true;
try {
- // eslint-disable-next-line es-x/no-object-defineproperty -- safe
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
Object.defineProperty([], 'length', { writable: false }).length = 1;
} catch (error) {
return error instanceof TypeError;
diff --git a/packages/core-js/internals/check-correctness-of-iteration.js b/packages/core-js/internals/check-correctness-of-iteration.js
index 1c7f613f1b84..c32be226a08c 100644
--- a/packages/core-js/internals/check-correctness-of-iteration.js
+++ b/packages/core-js/internals/check-correctness-of-iteration.js
@@ -16,7 +16,7 @@ try {
iteratorWithReturn[ITERATOR] = function () {
return this;
};
- // eslint-disable-next-line es-x/no-array-from, no-throw-literal -- required for testing
+ // eslint-disable-next-line es/no-array-from, no-throw-literal -- required for testing
Array.from(iteratorWithReturn, function () { throw 2; });
} catch (error) { /* empty */ }
diff --git a/packages/core-js/internals/correct-prototype-getter.js b/packages/core-js/internals/correct-prototype-getter.js
index cd17440239d0..6ce05e63608b 100644
--- a/packages/core-js/internals/correct-prototype-getter.js
+++ b/packages/core-js/internals/correct-prototype-getter.js
@@ -3,6 +3,6 @@ var fails = require('../internals/fails');
module.exports = !fails(function () {
function F() { /* empty */ }
F.prototype.constructor = null;
- // eslint-disable-next-line es-x/no-object-getprototypeof -- required for testing
+ // eslint-disable-next-line es/no-object-getprototypeof -- required for testing
return Object.getPrototypeOf(new F()) !== F.prototype;
});
diff --git a/packages/core-js/internals/define-global-property.js b/packages/core-js/internals/define-global-property.js
index d844b175dd0f..38cabe9e90f5 100644
--- a/packages/core-js/internals/define-global-property.js
+++ b/packages/core-js/internals/define-global-property.js
@@ -1,6 +1,6 @@
var global = require('../internals/global');
-// eslint-disable-next-line es-x/no-object-defineproperty -- safe
+// eslint-disable-next-line es/no-object-defineproperty -- safe
var defineProperty = Object.defineProperty;
module.exports = function (key, value) {
diff --git a/packages/core-js/internals/descriptors.js b/packages/core-js/internals/descriptors.js
index 43495e8af5d2..f93dd4c28ab6 100644
--- a/packages/core-js/internals/descriptors.js
+++ b/packages/core-js/internals/descriptors.js
@@ -2,6 +2,6 @@ var fails = require('../internals/fails');
// Detect IE8's incomplete defineProperty implementation
module.exports = !fails(function () {
- // eslint-disable-next-line es-x/no-object-defineproperty -- required for testing
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;
});
diff --git a/packages/core-js/internals/error-stack-installable.js b/packages/core-js/internals/error-stack-installable.js
index 34fead834740..ebdc5d0f923f 100644
--- a/packages/core-js/internals/error-stack-installable.js
+++ b/packages/core-js/internals/error-stack-installable.js
@@ -4,7 +4,7 @@ var createPropertyDescriptor = require('../internals/create-property-descriptor'
module.exports = !fails(function () {
var error = Error('a');
if (!('stack' in error)) return true;
- // eslint-disable-next-line es-x/no-object-defineproperty -- safe
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
Object.defineProperty(error, 'stack', createPropertyDescriptor(1, 7));
return error.stack !== 7;
});
diff --git a/packages/core-js/internals/error-to-string.js b/packages/core-js/internals/error-to-string.js
index a7104e6ed5e9..04000079f60d 100644
--- a/packages/core-js/internals/error-to-string.js
+++ b/packages/core-js/internals/error-to-string.js
@@ -10,7 +10,7 @@ var nativeErrorToString = Error.prototype.toString;
var INCORRECT_TO_STRING = fails(function () {
if (DESCRIPTORS) {
// Chrome 32- incorrectly call accessor
- // eslint-disable-next-line es-x/no-object-defineproperty -- safe
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
var object = create(Object.defineProperty({}, 'name', { get: function () {
return this === object;
} }));
diff --git a/packages/core-js/internals/freezing.js b/packages/core-js/internals/freezing.js
index a881254bc52e..51f25b555f50 100644
--- a/packages/core-js/internals/freezing.js
+++ b/packages/core-js/internals/freezing.js
@@ -1,6 +1,6 @@
var fails = require('../internals/fails');
module.exports = !fails(function () {
- // eslint-disable-next-line es-x/no-object-isextensible, es-x/no-object-preventextensions -- required for testing
+ // eslint-disable-next-line es/no-object-isextensible, es/no-object-preventextensions -- required for testing
return Object.isExtensible(Object.preventExtensions({}));
});
diff --git a/packages/core-js/internals/function-apply.js b/packages/core-js/internals/function-apply.js
index 4e501733161f..d9051329420d 100644
--- a/packages/core-js/internals/function-apply.js
+++ b/packages/core-js/internals/function-apply.js
@@ -4,7 +4,7 @@ var FunctionPrototype = Function.prototype;
var apply = FunctionPrototype.apply;
var call = FunctionPrototype.call;
-// eslint-disable-next-line es-x/no-reflect -- safe
+// eslint-disable-next-line es/no-reflect -- safe
module.exports = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call.bind(apply) : function () {
return call.apply(apply, arguments);
});
diff --git a/packages/core-js/internals/function-bind-native.js b/packages/core-js/internals/function-bind-native.js
index c572e873467b..11d87d4955f9 100644
--- a/packages/core-js/internals/function-bind-native.js
+++ b/packages/core-js/internals/function-bind-native.js
@@ -1,7 +1,7 @@
var fails = require('../internals/fails');
module.exports = !fails(function () {
- // eslint-disable-next-line es-x/no-function-prototype-bind -- safe
+ // eslint-disable-next-line es/no-function-prototype-bind -- safe
var test = (function () { /* empty */ }).bind();
// eslint-disable-next-line no-prototype-builtins -- safe
return typeof test != 'function' || test.hasOwnProperty('prototype');
diff --git a/packages/core-js/internals/function-name.js b/packages/core-js/internals/function-name.js
index 3118036c1757..1655ae586d0a 100644
--- a/packages/core-js/internals/function-name.js
+++ b/packages/core-js/internals/function-name.js
@@ -2,7 +2,7 @@ var DESCRIPTORS = require('../internals/descriptors');
var hasOwn = require('../internals/has-own-property');
var FunctionPrototype = Function.prototype;
-// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;
var EXISTS = hasOwn(FunctionPrototype, 'name');
diff --git a/packages/core-js/internals/get-map-iterator.js b/packages/core-js/internals/get-map-iterator.js
index bc51174c3103..a0d0c8929f1c 100644
--- a/packages/core-js/internals/get-map-iterator.js
+++ b/packages/core-js/internals/get-map-iterator.js
@@ -1,6 +1,6 @@
var call = require('../internals/function-call');
module.exports = function (it) {
- // eslint-disable-next-line es-x/no-map -- safe
+ // eslint-disable-next-line es/no-map -- safe
return call(Map.prototype.entries, it);
};
diff --git a/packages/core-js/internals/get-set-iterator.js b/packages/core-js/internals/get-set-iterator.js
index 14d01305ad89..f459ba633f50 100644
--- a/packages/core-js/internals/get-set-iterator.js
+++ b/packages/core-js/internals/get-set-iterator.js
@@ -1,6 +1,6 @@
var call = require('../internals/function-call');
module.exports = function (it) {
- // eslint-disable-next-line es-x/no-set -- safe
+ // eslint-disable-next-line es/no-set -- safe
return call(Set.prototype.values, it);
};
diff --git a/packages/core-js/internals/global.js b/packages/core-js/internals/global.js
index de6636cd2676..143f8788952d 100644
--- a/packages/core-js/internals/global.js
+++ b/packages/core-js/internals/global.js
@@ -4,7 +4,7 @@ var check = function (it) {
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
module.exports =
- // eslint-disable-next-line es-x/no-global-this -- safe
+ // eslint-disable-next-line es/no-global-this -- safe
check(typeof globalThis == 'object' && globalThis) ||
check(typeof window == 'object' && window) ||
// eslint-disable-next-line no-restricted-globals -- safe
diff --git a/packages/core-js/internals/has-own-property.js b/packages/core-js/internals/has-own-property.js
index 538324d8c415..abfb9a2a33ab 100644
--- a/packages/core-js/internals/has-own-property.js
+++ b/packages/core-js/internals/has-own-property.js
@@ -5,7 +5,7 @@ var hasOwnProperty = uncurryThis({}.hasOwnProperty);
// `HasOwnProperty` abstract operation
// https://tc39.es/ecma262/#sec-hasownproperty
-// eslint-disable-next-line es-x/no-object-hasown -- safe
+// eslint-disable-next-line es/no-object-hasown -- safe
module.exports = Object.hasOwn || function hasOwn(it, key) {
return hasOwnProperty(toObject(it), key);
};
diff --git a/packages/core-js/internals/ie8-dom-define.js b/packages/core-js/internals/ie8-dom-define.js
index f23a03293a8c..ab18295c2a76 100644
--- a/packages/core-js/internals/ie8-dom-define.js
+++ b/packages/core-js/internals/ie8-dom-define.js
@@ -4,7 +4,7 @@ var createElement = require('../internals/document-create-element');
// Thanks to IE8 for its funny defineProperty
module.exports = !DESCRIPTORS && !fails(function () {
- // eslint-disable-next-line es-x/no-object-defineproperty -- required for testing
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
return Object.defineProperty(createElement('div'), 'a', {
get: function () { return 7; }
}).a != 7;
diff --git a/packages/core-js/internals/is-array.js b/packages/core-js/internals/is-array.js
index 1fff36acbff2..258cfc9f778c 100644
--- a/packages/core-js/internals/is-array.js
+++ b/packages/core-js/internals/is-array.js
@@ -2,7 +2,7 @@ var classof = require('../internals/classof-raw');
// `IsArray` abstract operation
// https://tc39.es/ecma262/#sec-isarray
-// eslint-disable-next-line es-x/no-array-isarray -- safe
+// eslint-disable-next-line es/no-array-isarray -- safe
module.exports = Array.isArray || function isArray(argument) {
return classof(argument) == 'Array';
};
diff --git a/packages/core-js/internals/is-integral-number.js b/packages/core-js/internals/is-integral-number.js
index b76278239697..4f4e03ffd773 100644
--- a/packages/core-js/internals/is-integral-number.js
+++ b/packages/core-js/internals/is-integral-number.js
@@ -4,7 +4,7 @@ var floor = Math.floor;
// `IsIntegralNumber` abstract operation
// https://tc39.es/ecma262/#sec-isintegralnumber
-// eslint-disable-next-line es-x/no-number-isinteger -- safe
+// eslint-disable-next-line es/no-number-isinteger -- safe
module.exports = Number.isInteger || function isInteger(it) {
return !isObject(it) && isFinite(it) && floor(it) === it;
};
diff --git a/packages/core-js/internals/iterators-core.js b/packages/core-js/internals/iterators-core.js
index 86a35e0b0eb0..9ebcaae6048c 100644
--- a/packages/core-js/internals/iterators-core.js
+++ b/packages/core-js/internals/iterators-core.js
@@ -15,7 +15,7 @@ var BUGGY_SAFARI_ITERATORS = false;
// https://tc39.es/ecma262/#sec-%iteratorprototype%-object
var IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;
-/* eslint-disable es-x/no-array-prototype-keys -- safe */
+/* eslint-disable es/no-array-prototype-keys -- safe */
if ([].keys) {
arrayIterator = [].keys();
// Safari 8 has buggy iterators w/o `next`
diff --git a/packages/core-js/internals/make-built-in.js b/packages/core-js/internals/make-built-in.js
index e9347fb0feab..91436ac33f3c 100644
--- a/packages/core-js/internals/make-built-in.js
+++ b/packages/core-js/internals/make-built-in.js
@@ -8,7 +8,7 @@ var InternalStateModule = require('../internals/internal-state');
var enforceInternalState = InternalStateModule.enforce;
var getInternalState = InternalStateModule.get;
-// eslint-disable-next-line es-x/no-object-defineproperty -- safe
+// eslint-disable-next-line es/no-object-defineproperty -- safe
var defineProperty = Object.defineProperty;
var CONFIGURABLE_LENGTH = DESCRIPTORS && !fails(function () {
diff --git a/packages/core-js/internals/math-expm1.js b/packages/core-js/internals/math-expm1.js
index 73fbaed248eb..450792849796 100644
--- a/packages/core-js/internals/math-expm1.js
+++ b/packages/core-js/internals/math-expm1.js
@@ -1,4 +1,4 @@
-// eslint-disable-next-line es-x/no-math-expm1 -- safe
+// eslint-disable-next-line es/no-math-expm1 -- safe
var $expm1 = Math.expm1;
var exp = Math.exp;
diff --git a/packages/core-js/internals/math-fround.js b/packages/core-js/internals/math-fround.js
index d5491e36b942..df3b03eb83e0 100644
--- a/packages/core-js/internals/math-fround.js
+++ b/packages/core-js/internals/math-fround.js
@@ -13,7 +13,7 @@ var roundTiesToEven = function (n) {
// `Math.fround` method implementation
// https://tc39.es/ecma262/#sec-math.fround
-// eslint-disable-next-line es-x/no-math-fround -- safe
+// eslint-disable-next-line es/no-math-fround -- safe
module.exports = Math.fround || function fround(x) {
var n = +x;
var $abs = abs(n);
diff --git a/packages/core-js/internals/math-log10.js b/packages/core-js/internals/math-log10.js
index 3a359803915e..7b43051fbe8e 100644
--- a/packages/core-js/internals/math-log10.js
+++ b/packages/core-js/internals/math-log10.js
@@ -1,7 +1,7 @@
var log = Math.log;
var LOG10E = Math.LOG10E;
-// eslint-disable-next-line es-x/no-math-log10 -- safe
+// eslint-disable-next-line es/no-math-log10 -- safe
module.exports = Math.log10 || function log10(x) {
return log(x) * LOG10E;
};
diff --git a/packages/core-js/internals/math-log1p.js b/packages/core-js/internals/math-log1p.js
index 0e7fbdfd956a..a49be5443b02 100644
--- a/packages/core-js/internals/math-log1p.js
+++ b/packages/core-js/internals/math-log1p.js
@@ -2,7 +2,7 @@ var log = Math.log;
// `Math.log1p` method implementation
// https://tc39.es/ecma262/#sec-math.log1p
-// eslint-disable-next-line es-x/no-math-log1p -- safe
+// eslint-disable-next-line es/no-math-log1p -- safe
module.exports = Math.log1p || function log1p(x) {
var n = +x;
return n > -1e-8 && n < 1e-8 ? n - n * n / 2 : log(1 + n);
diff --git a/packages/core-js/internals/math-sign.js b/packages/core-js/internals/math-sign.js
index fc89890136bd..ff10a5a13ae5 100644
--- a/packages/core-js/internals/math-sign.js
+++ b/packages/core-js/internals/math-sign.js
@@ -1,6 +1,6 @@
// `Math.sign` method implementation
// https://tc39.es/ecma262/#sec-math.sign
-// eslint-disable-next-line es-x/no-math-sign -- safe
+// eslint-disable-next-line es/no-math-sign -- safe
module.exports = Math.sign || function sign(x) {
var n = +x;
// eslint-disable-next-line no-self-compare -- NaN check
diff --git a/packages/core-js/internals/math-trunc.js b/packages/core-js/internals/math-trunc.js
index 835f7fdfc63f..21a20b7f2490 100644
--- a/packages/core-js/internals/math-trunc.js
+++ b/packages/core-js/internals/math-trunc.js
@@ -3,7 +3,7 @@ var floor = Math.floor;
// `Math.trunc` method
// https://tc39.es/ecma262/#sec-math.trunc
-// eslint-disable-next-line es-x/no-math-trunc -- safe
+// eslint-disable-next-line es/no-math-trunc -- safe
module.exports = Math.trunc || function trunc(x) {
var n = +x;
return (n > 0 ? floor : ceil)(n);
diff --git a/packages/core-js/internals/number-is-finite.js b/packages/core-js/internals/number-is-finite.js
index a00171c5542b..5a812546d380 100644
--- a/packages/core-js/internals/number-is-finite.js
+++ b/packages/core-js/internals/number-is-finite.js
@@ -4,7 +4,7 @@ var globalIsFinite = global.isFinite;
// `Number.isFinite` method
// https://tc39.es/ecma262/#sec-number.isfinite
-// eslint-disable-next-line es-x/no-number-isfinite -- safe
+// eslint-disable-next-line es/no-number-isfinite -- safe
module.exports = Number.isFinite || function isFinite(it) {
return typeof it == 'number' && globalIsFinite(it);
};
diff --git a/packages/core-js/internals/object-assign.js b/packages/core-js/internals/object-assign.js
index 553937f4495e..91076d066beb 100644
--- a/packages/core-js/internals/object-assign.js
+++ b/packages/core-js/internals/object-assign.js
@@ -9,9 +9,9 @@ var propertyIsEnumerableModule = require('../internals/object-property-is-enumer
var toObject = require('../internals/to-object');
var IndexedObject = require('../internals/indexed-object');
-// eslint-disable-next-line es-x/no-object-assign -- safe
+// eslint-disable-next-line es/no-object-assign -- safe
var $assign = Object.assign;
-// eslint-disable-next-line es-x/no-object-defineproperty -- required for testing
+// eslint-disable-next-line es/no-object-defineproperty -- required for testing
var defineProperty = Object.defineProperty;
var concat = uncurryThis([].concat);
@@ -31,7 +31,7 @@ module.exports = !$assign || fails(function () {
// should work with symbols and should have deterministic property order (V8 bug)
var A = {};
var B = {};
- // eslint-disable-next-line es-x/no-symbol -- safe
+ // eslint-disable-next-line es/no-symbol -- safe
var symbol = Symbol();
var alphabet = 'abcdefghijklmnopqrst';
A[symbol] = 7;
diff --git a/packages/core-js/internals/object-create.js b/packages/core-js/internals/object-create.js
index 19cc3196c324..304750b12091 100644
--- a/packages/core-js/internals/object-create.js
+++ b/packages/core-js/internals/object-create.js
@@ -69,7 +69,7 @@ hiddenKeys[IE_PROTO] = true;
// `Object.create` method
// https://tc39.es/ecma262/#sec-object.create
-// eslint-disable-next-line es-x/no-object-create -- safe
+// eslint-disable-next-line es/no-object-create -- safe
module.exports = Object.create || function create(O, Properties) {
var result;
if (O !== null) {
diff --git a/packages/core-js/internals/object-define-properties.js b/packages/core-js/internals/object-define-properties.js
index 976478816bb6..30199d47061d 100644
--- a/packages/core-js/internals/object-define-properties.js
+++ b/packages/core-js/internals/object-define-properties.js
@@ -7,7 +7,7 @@ var objectKeys = require('../internals/object-keys');
// `Object.defineProperties` method
// https://tc39.es/ecma262/#sec-object.defineproperties
-// eslint-disable-next-line es-x/no-object-defineproperties -- safe
+// eslint-disable-next-line es/no-object-defineproperties -- safe
exports.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
anObject(O);
var props = toIndexedObject(Properties);
diff --git a/packages/core-js/internals/object-define-property.js b/packages/core-js/internals/object-define-property.js
index 48ba782cb485..f1abab7cf043 100644
--- a/packages/core-js/internals/object-define-property.js
+++ b/packages/core-js/internals/object-define-property.js
@@ -5,9 +5,9 @@ var anObject = require('../internals/an-object');
var toPropertyKey = require('../internals/to-property-key');
var $TypeError = TypeError;
-// eslint-disable-next-line es-x/no-object-defineproperty -- safe
+// eslint-disable-next-line es/no-object-defineproperty -- safe
var $defineProperty = Object.defineProperty;
-// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
var ENUMERABLE = 'enumerable';
var CONFIGURABLE = 'configurable';
diff --git a/packages/core-js/internals/object-get-own-property-descriptor.js b/packages/core-js/internals/object-get-own-property-descriptor.js
index 3c5078ec93d9..12e9fd03a860 100644
--- a/packages/core-js/internals/object-get-own-property-descriptor.js
+++ b/packages/core-js/internals/object-get-own-property-descriptor.js
@@ -7,7 +7,7 @@ var toPropertyKey = require('../internals/to-property-key');
var hasOwn = require('../internals/has-own-property');
var IE8_DOM_DEFINE = require('../internals/ie8-dom-define');
-// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
// `Object.getOwnPropertyDescriptor` method
diff --git a/packages/core-js/internals/object-get-own-property-names-external.js b/packages/core-js/internals/object-get-own-property-names-external.js
index f33f8ca82823..32d2b73ffe53 100644
--- a/packages/core-js/internals/object-get-own-property-names-external.js
+++ b/packages/core-js/internals/object-get-own-property-names-external.js
@@ -1,4 +1,4 @@
-/* eslint-disable es-x/no-object-getownpropertynames -- safe */
+/* eslint-disable es/no-object-getownpropertynames -- safe */
var classof = require('../internals/classof-raw');
var toIndexedObject = require('../internals/to-indexed-object');
var $getOwnPropertyNames = require('../internals/object-get-own-property-names').f;
diff --git a/packages/core-js/internals/object-get-own-property-names.js b/packages/core-js/internals/object-get-own-property-names.js
index 0231d67cf285..b330d1b4252b 100644
--- a/packages/core-js/internals/object-get-own-property-names.js
+++ b/packages/core-js/internals/object-get-own-property-names.js
@@ -5,7 +5,7 @@ var hiddenKeys = enumBugKeys.concat('length', 'prototype');
// `Object.getOwnPropertyNames` method
// https://tc39.es/ecma262/#sec-object.getownpropertynames
-// eslint-disable-next-line es-x/no-object-getownpropertynames -- safe
+// eslint-disable-next-line es/no-object-getownpropertynames -- safe
exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
return internalObjectKeys(O, hiddenKeys);
};
diff --git a/packages/core-js/internals/object-get-own-property-symbols.js b/packages/core-js/internals/object-get-own-property-symbols.js
index 4dbd37f76291..f55ead06cf14 100644
--- a/packages/core-js/internals/object-get-own-property-symbols.js
+++ b/packages/core-js/internals/object-get-own-property-symbols.js
@@ -1,2 +1,2 @@
-// eslint-disable-next-line es-x/no-object-getownpropertysymbols -- safe
+// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
exports.f = Object.getOwnPropertySymbols;
diff --git a/packages/core-js/internals/object-get-prototype-of.js b/packages/core-js/internals/object-get-prototype-of.js
index 3af0e605f510..2380d4cdbba3 100644
--- a/packages/core-js/internals/object-get-prototype-of.js
+++ b/packages/core-js/internals/object-get-prototype-of.js
@@ -10,7 +10,7 @@ var ObjectPrototype = $Object.prototype;
// `Object.getPrototypeOf` method
// https://tc39.es/ecma262/#sec-object.getprototypeof
-// eslint-disable-next-line es-x/no-object-getprototypeof -- safe
+// eslint-disable-next-line es/no-object-getprototypeof -- safe
module.exports = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) {
var object = toObject(O);
if (hasOwn(object, IE_PROTO)) return object[IE_PROTO];
diff --git a/packages/core-js/internals/object-is-extensible.js b/packages/core-js/internals/object-is-extensible.js
index 8202e48f29e0..93cadf333d67 100644
--- a/packages/core-js/internals/object-is-extensible.js
+++ b/packages/core-js/internals/object-is-extensible.js
@@ -3,7 +3,7 @@ var isObject = require('../internals/is-object');
var classof = require('../internals/classof-raw');
var ARRAY_BUFFER_NON_EXTENSIBLE = require('../internals/array-buffer-non-extensible');
-// eslint-disable-next-line es-x/no-object-isextensible -- safe
+// eslint-disable-next-line es/no-object-isextensible -- safe
var $isExtensible = Object.isExtensible;
var FAILS_ON_PRIMITIVES = fails(function () { $isExtensible(1); });
diff --git a/packages/core-js/internals/object-keys.js b/packages/core-js/internals/object-keys.js
index df5fb19f9588..bceea8b7a1bc 100644
--- a/packages/core-js/internals/object-keys.js
+++ b/packages/core-js/internals/object-keys.js
@@ -3,7 +3,7 @@ var enumBugKeys = require('../internals/enum-bug-keys');
// `Object.keys` method
// https://tc39.es/ecma262/#sec-object.keys
-// eslint-disable-next-line es-x/no-object-keys -- safe
+// eslint-disable-next-line es/no-object-keys -- safe
module.exports = Object.keys || function keys(O) {
return internalObjectKeys(O, enumBugKeys);
};
diff --git a/packages/core-js/internals/object-property-is-enumerable.js b/packages/core-js/internals/object-property-is-enumerable.js
index 8262ef8c7642..f262d100ec57 100644
--- a/packages/core-js/internals/object-property-is-enumerable.js
+++ b/packages/core-js/internals/object-property-is-enumerable.js
@@ -1,6 +1,6 @@
'use strict';
var $propertyIsEnumerable = {}.propertyIsEnumerable;
-// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
// Nashorn ~ JDK8 bug
diff --git a/packages/core-js/internals/object-prototype-accessors-forced.js b/packages/core-js/internals/object-prototype-accessors-forced.js
index 5a66f6ffa1bc..579bb781b52b 100644
--- a/packages/core-js/internals/object-prototype-accessors-forced.js
+++ b/packages/core-js/internals/object-prototype-accessors-forced.js
@@ -11,7 +11,7 @@ module.exports = IS_PURE || !fails(function () {
if (WEBKIT && WEBKIT < 535) return;
var key = Math.random();
// In FF throws only define methods
- // eslint-disable-next-line no-undef, no-useless-call, es-x/no-legacy-object-prototype-accessor-methods -- required for testing
+ // eslint-disable-next-line no-undef, no-useless-call, es/no-legacy-object-prototype-accessor-methods -- required for testing
__defineSetter__.call(null, key, function () { /* empty */ });
delete global[key];
});
diff --git a/packages/core-js/internals/object-set-prototype-of.js b/packages/core-js/internals/object-set-prototype-of.js
index ecf0f48398e4..a1feedbbdb1a 100644
--- a/packages/core-js/internals/object-set-prototype-of.js
+++ b/packages/core-js/internals/object-set-prototype-of.js
@@ -6,13 +6,13 @@ var aPossiblePrototype = require('../internals/a-possible-prototype');
// `Object.setPrototypeOf` method
// https://tc39.es/ecma262/#sec-object.setprototypeof
// Works with __proto__ only. Old v8 can't work with null proto objects.
-// eslint-disable-next-line es-x/no-object-setprototypeof -- safe
+// eslint-disable-next-line es/no-object-setprototypeof -- safe
module.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {
var CORRECT_SETTER = false;
var test = {};
var setter;
try {
- // eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
setter = uncurryThis(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);
setter(test, []);
CORRECT_SETTER = test instanceof Array;
diff --git a/packages/core-js/internals/same-value.js b/packages/core-js/internals/same-value.js
index e632f47812df..f364cdf208e9 100644
--- a/packages/core-js/internals/same-value.js
+++ b/packages/core-js/internals/same-value.js
@@ -1,6 +1,6 @@
// `SameValue` abstract operation
// https://tc39.es/ecma262/#sec-samevalue
-// eslint-disable-next-line es-x/no-object-is -- safe
+// eslint-disable-next-line es/no-object-is -- safe
module.exports = Object.is || function is(x, y) {
// eslint-disable-next-line no-self-compare -- NaN check
return x === y ? x !== 0 || 1 / x === 1 / y : x != x && y != y;
diff --git a/packages/core-js/internals/string-trim-end.js b/packages/core-js/internals/string-trim-end.js
index a3ebc071a8c6..a57c7d688a46 100644
--- a/packages/core-js/internals/string-trim-end.js
+++ b/packages/core-js/internals/string-trim-end.js
@@ -7,5 +7,5 @@ var forcedStringTrimMethod = require('../internals/string-trim-forced');
// https://tc39.es/ecma262/#String.prototype.trimright
module.exports = forcedStringTrimMethod('trimEnd') ? function trimEnd() {
return $trimEnd(this);
-// eslint-disable-next-line es-x/no-string-prototype-trimstart-trimend -- safe
+// eslint-disable-next-line es/no-string-prototype-trimstart-trimend -- safe
} : ''.trimEnd;
diff --git a/packages/core-js/internals/string-trim-start.js b/packages/core-js/internals/string-trim-start.js
index 324bb5160afb..b1e16cfc8db3 100644
--- a/packages/core-js/internals/string-trim-start.js
+++ b/packages/core-js/internals/string-trim-start.js
@@ -7,5 +7,5 @@ var forcedStringTrimMethod = require('../internals/string-trim-forced');
// https://tc39.es/ecma262/#String.prototype.trimleft
module.exports = forcedStringTrimMethod('trimStart') ? function trimStart() {
return $trimStart(this);
-// eslint-disable-next-line es-x/no-string-prototype-trimstart-trimend -- safe
+// eslint-disable-next-line es/no-string-prototype-trimstart-trimend -- safe
} : ''.trimStart;
diff --git a/packages/core-js/internals/symbol-constructor-detection.js b/packages/core-js/internals/symbol-constructor-detection.js
index f4f615750dd5..8c85dd4b97e4 100644
--- a/packages/core-js/internals/symbol-constructor-detection.js
+++ b/packages/core-js/internals/symbol-constructor-detection.js
@@ -1,8 +1,8 @@
-/* eslint-disable es-x/no-symbol -- required for testing */
+/* eslint-disable es/no-symbol -- required for testing */
var V8_VERSION = require('../internals/engine-v8-version');
var fails = require('../internals/fails');
-// eslint-disable-next-line es-x/no-object-getownpropertysymbols -- required for testing
+// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
module.exports = !!Object.getOwnPropertySymbols && !fails(function () {
var symbol = Symbol();
// Chrome 38 Symbol has incorrect toString conversion
diff --git a/packages/core-js/internals/symbol-registry-detection.js b/packages/core-js/internals/symbol-registry-detection.js
index 3b776473b3a3..6a8e6c6569e0 100644
--- a/packages/core-js/internals/symbol-registry-detection.js
+++ b/packages/core-js/internals/symbol-registry-detection.js
@@ -1,4 +1,4 @@
var NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');
-/* eslint-disable es-x/no-symbol -- safe */
+/* eslint-disable es/no-symbol -- safe */
module.exports = NATIVE_SYMBOL && !!Symbol['for'] && !!Symbol.keyFor;
diff --git a/packages/core-js/internals/task.js b/packages/core-js/internals/task.js
index 9a91a462ae27..ca3b2402f308 100644
--- a/packages/core-js/internals/task.js
+++ b/packages/core-js/internals/task.js
@@ -21,11 +21,11 @@ var String = global.String;
var counter = 0;
var queue = {};
var ONREADYSTATECHANGE = 'onreadystatechange';
-var location, defer, channel, port;
+var $location, defer, channel, port;
try {
// Deno throws a ReferenceError on `location` access without `--location` flag
- location = global.location;
+ $location = global.location;
} catch (error) { /* empty */ }
var run = function (id) {
@@ -48,7 +48,7 @@ var listener = function (event) {
var post = function (id) {
// old engines have not location.origin
- global.postMessage(String(id), location.protocol + '//' + location.host);
+ global.postMessage(String(id), $location.protocol + '//' + $location.host);
};
// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
@@ -89,7 +89,7 @@ if (!set || !clear) {
global.addEventListener &&
isCallable(global.postMessage) &&
!global.importScripts &&
- location && location.protocol !== 'file:' &&
+ $location && $location.protocol !== 'file:' &&
!fails(post)
) {
defer = post;
diff --git a/packages/core-js/internals/to-big-int.js b/packages/core-js/internals/to-big-int.js
index 5d785983fa7f..9c6fa670323f 100644
--- a/packages/core-js/internals/to-big-int.js
+++ b/packages/core-js/internals/to-big-int.js
@@ -7,6 +7,6 @@ var $TypeError = TypeError;
module.exports = function (argument) {
var prim = toPrimitive(argument, 'number');
if (typeof prim == 'number') throw $TypeError("Can't convert number to bigint");
- // eslint-disable-next-line es-x/no-bigint -- safe
+ // eslint-disable-next-line es/no-bigint -- safe
return BigInt(prim);
};
diff --git a/packages/core-js/internals/use-symbol-as-uid.js b/packages/core-js/internals/use-symbol-as-uid.js
index 5cd27385f062..19c63f41346c 100644
--- a/packages/core-js/internals/use-symbol-as-uid.js
+++ b/packages/core-js/internals/use-symbol-as-uid.js
@@ -1,4 +1,4 @@
-/* eslint-disable es-x/no-symbol -- required for testing */
+/* eslint-disable es/no-symbol -- required for testing */
var NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');
module.exports = NATIVE_SYMBOL
diff --git a/packages/core-js/internals/v8-prototype-define-bug.js b/packages/core-js/internals/v8-prototype-define-bug.js
index 17f78d056e3a..7c57aa99fbbb 100644
--- a/packages/core-js/internals/v8-prototype-define-bug.js
+++ b/packages/core-js/internals/v8-prototype-define-bug.js
@@ -4,7 +4,7 @@ var fails = require('../internals/fails');
// V8 ~ Chrome 36-
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
module.exports = DESCRIPTORS && fails(function () {
- // eslint-disable-next-line es-x/no-object-defineproperty -- required for testing
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
value: 42,
writable: false
diff --git a/packages/core-js/modules/es.array.for-each.js b/packages/core-js/modules/es.array.for-each.js
index 812668ddb9d3..55934d03017f 100644
--- a/packages/core-js/modules/es.array.for-each.js
+++ b/packages/core-js/modules/es.array.for-each.js
@@ -4,7 +4,7 @@ var forEach = require('../internals/array-for-each');
// `Array.prototype.forEach` method
// https://tc39.es/ecma262/#sec-array.prototype.foreach
-// eslint-disable-next-line es-x/no-array-prototype-foreach -- safe
+// eslint-disable-next-line es/no-array-prototype-foreach -- safe
$({ target: 'Array', proto: true, forced: [].forEach != forEach }, {
forEach: forEach
});
diff --git a/packages/core-js/modules/es.array.from.js b/packages/core-js/modules/es.array.from.js
index 4edf7e919478..241f6ac866c3 100644
--- a/packages/core-js/modules/es.array.from.js
+++ b/packages/core-js/modules/es.array.from.js
@@ -3,7 +3,7 @@ var from = require('../internals/array-from');
var checkCorrectnessOfIteration = require('../internals/check-correctness-of-iteration');
var INCORRECT_ITERATION = !checkCorrectnessOfIteration(function (iterable) {
- // eslint-disable-next-line es-x/no-array-from -- required for testing
+ // eslint-disable-next-line es/no-array-from -- required for testing
Array.from(iterable);
});
diff --git a/packages/core-js/modules/es.array.index-of.js b/packages/core-js/modules/es.array.index-of.js
index 358586d03f23..9926ff1fd8e5 100644
--- a/packages/core-js/modules/es.array.index-of.js
+++ b/packages/core-js/modules/es.array.index-of.js
@@ -1,5 +1,5 @@
'use strict';
-/* eslint-disable es-x/no-array-prototype-indexof -- required for testing */
+/* eslint-disable es/no-array-prototype-indexof -- required for testing */
var $ = require('../internals/export');
var uncurryThis = require('../internals/function-uncurry-this');
var $indexOf = require('../internals/array-includes').indexOf;
diff --git a/packages/core-js/modules/es.array.last-index-of.js b/packages/core-js/modules/es.array.last-index-of.js
index 9d15f648a961..7ee20dfdf1c0 100644
--- a/packages/core-js/modules/es.array.last-index-of.js
+++ b/packages/core-js/modules/es.array.last-index-of.js
@@ -3,7 +3,7 @@ var lastIndexOf = require('../internals/array-last-index-of');
// `Array.prototype.lastIndexOf` method
// https://tc39.es/ecma262/#sec-array.prototype.lastindexof
-// eslint-disable-next-line es-x/no-array-prototype-lastindexof -- required for testing
+// eslint-disable-next-line es/no-array-prototype-lastindexof -- required for testing
$({ target: 'Array', proto: true, forced: lastIndexOf !== [].lastIndexOf }, {
lastIndexOf: lastIndexOf
});
diff --git a/packages/core-js/modules/es.array.of.js b/packages/core-js/modules/es.array.of.js
index ca1cc7b42b68..4dbb2341bd50 100644
--- a/packages/core-js/modules/es.array.of.js
+++ b/packages/core-js/modules/es.array.of.js
@@ -8,7 +8,7 @@ var $Array = Array;
var ISNT_GENERIC = fails(function () {
function F() { /* empty */ }
- // eslint-disable-next-line es-x/no-array-of -- safe
+ // eslint-disable-next-line es/no-array-of -- safe
return !($Array.of.call(F) instanceof F);
});
diff --git a/packages/core-js/modules/es.array.push.js b/packages/core-js/modules/es.array.push.js
index c609247037f9..48929a2a046a 100644
--- a/packages/core-js/modules/es.array.push.js
+++ b/packages/core-js/modules/es.array.push.js
@@ -14,7 +14,7 @@ var INCORRECT_TO_LENGTH = fails(function () {
// https://bugs.chromium.org/p/v8/issues/detail?id=12681
var SILENT_ON_NON_WRITABLE_LENGTH = !function () {
try {
- // eslint-disable-next-line es-x/no-object-defineproperty -- safe
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
Object.defineProperty([], 'length', { writable: false }).push();
} catch (error) {
return error instanceof TypeError;
diff --git a/packages/core-js/modules/es.array.unshift.js b/packages/core-js/modules/es.array.unshift.js
index fcf42b126071..6ae7af9da29c 100644
--- a/packages/core-js/modules/es.array.unshift.js
+++ b/packages/core-js/modules/es.array.unshift.js
@@ -12,7 +12,7 @@ var INCORRECT_RESULT = [].unshift(0) !== 1;
// V8 ~ Chrome < 71 and Safari <= 15.4, FF < 23 throws InternalError
var SILENT_ON_NON_WRITABLE_LENGTH = !function () {
try {
- // eslint-disable-next-line es-x/no-object-defineproperty -- safe
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
Object.defineProperty([], 'length', { writable: false }).unshift();
} catch (error) {
return error instanceof TypeError;
diff --git a/packages/core-js/modules/es.math.acosh.js b/packages/core-js/modules/es.math.acosh.js
index 82d67a0f245d..b2c732f0ef3d 100644
--- a/packages/core-js/modules/es.math.acosh.js
+++ b/packages/core-js/modules/es.math.acosh.js
@@ -1,7 +1,7 @@
var $ = require('../internals/export');
var log1p = require('../internals/math-log1p');
-// eslint-disable-next-line es-x/no-math-acosh -- required for testing
+// eslint-disable-next-line es/no-math-acosh -- required for testing
var $acosh = Math.acosh;
var log = Math.log;
var sqrt = Math.sqrt;
diff --git a/packages/core-js/modules/es.math.asinh.js b/packages/core-js/modules/es.math.asinh.js
index ffc9b47f978f..a9c104528aa3 100644
--- a/packages/core-js/modules/es.math.asinh.js
+++ b/packages/core-js/modules/es.math.asinh.js
@@ -1,6 +1,6 @@
var $ = require('../internals/export');
-// eslint-disable-next-line es-x/no-math-asinh -- required for testing
+// eslint-disable-next-line es/no-math-asinh -- required for testing
var $asinh = Math.asinh;
var log = Math.log;
var sqrt = Math.sqrt;
diff --git a/packages/core-js/modules/es.math.atanh.js b/packages/core-js/modules/es.math.atanh.js
index 1771d371d00c..a55426c743d6 100644
--- a/packages/core-js/modules/es.math.atanh.js
+++ b/packages/core-js/modules/es.math.atanh.js
@@ -1,6 +1,6 @@
var $ = require('../internals/export');
-// eslint-disable-next-line es-x/no-math-atanh -- required for testing
+// eslint-disable-next-line es/no-math-atanh -- required for testing
var $atanh = Math.atanh;
var log = Math.log;
diff --git a/packages/core-js/modules/es.math.cosh.js b/packages/core-js/modules/es.math.cosh.js
index 6898e504eee9..4c666c093425 100644
--- a/packages/core-js/modules/es.math.cosh.js
+++ b/packages/core-js/modules/es.math.cosh.js
@@ -1,7 +1,7 @@
var $ = require('../internals/export');
var expm1 = require('../internals/math-expm1');
-// eslint-disable-next-line es-x/no-math-cosh -- required for testing
+// eslint-disable-next-line es/no-math-cosh -- required for testing
var $cosh = Math.cosh;
var abs = Math.abs;
var E = Math.E;
diff --git a/packages/core-js/modules/es.math.expm1.js b/packages/core-js/modules/es.math.expm1.js
index 21d0ccb3ef55..1ae920be1a7f 100644
--- a/packages/core-js/modules/es.math.expm1.js
+++ b/packages/core-js/modules/es.math.expm1.js
@@ -3,5 +3,5 @@ var expm1 = require('../internals/math-expm1');
// `Math.expm1` method
// https://tc39.es/ecma262/#sec-math.expm1
-// eslint-disable-next-line es-x/no-math-expm1 -- required for testing
+// eslint-disable-next-line es/no-math-expm1 -- required for testing
$({ target: 'Math', stat: true, forced: expm1 != Math.expm1 }, { expm1: expm1 });
diff --git a/packages/core-js/modules/es.math.hypot.js b/packages/core-js/modules/es.math.hypot.js
index 348ba465000d..5b5b0edae28f 100644
--- a/packages/core-js/modules/es.math.hypot.js
+++ b/packages/core-js/modules/es.math.hypot.js
@@ -1,6 +1,6 @@
var $ = require('../internals/export');
-// eslint-disable-next-line es-x/no-math-hypot -- required for testing
+// eslint-disable-next-line es/no-math-hypot -- required for testing
var $hypot = Math.hypot;
var abs = Math.abs;
var sqrt = Math.sqrt;
diff --git a/packages/core-js/modules/es.math.imul.js b/packages/core-js/modules/es.math.imul.js
index 4745f7244baa..3ccdfbd79f7f 100644
--- a/packages/core-js/modules/es.math.imul.js
+++ b/packages/core-js/modules/es.math.imul.js
@@ -1,7 +1,7 @@
var $ = require('../internals/export');
var fails = require('../internals/fails');
-// eslint-disable-next-line es-x/no-math-imul -- required for testing
+// eslint-disable-next-line es/no-math-imul -- required for testing
var $imul = Math.imul;
var FORCED = fails(function () {
diff --git a/packages/core-js/modules/es.math.sinh.js b/packages/core-js/modules/es.math.sinh.js
index c98f1f9cc544..55b7230753fa 100644
--- a/packages/core-js/modules/es.math.sinh.js
+++ b/packages/core-js/modules/es.math.sinh.js
@@ -7,7 +7,7 @@ var exp = Math.exp;
var E = Math.E;
var FORCED = fails(function () {
- // eslint-disable-next-line es-x/no-math-sinh -- required for testing
+ // eslint-disable-next-line es/no-math-sinh -- required for testing
return Math.sinh(-2e-17) != -2e-17;
});
diff --git a/packages/core-js/modules/es.number.parse-float.js b/packages/core-js/modules/es.number.parse-float.js
index 376a6a920dad..1c89294b8d02 100644
--- a/packages/core-js/modules/es.number.parse-float.js
+++ b/packages/core-js/modules/es.number.parse-float.js
@@ -3,7 +3,7 @@ var parseFloat = require('../internals/number-parse-float');
// `Number.parseFloat` method
// https://tc39.es/ecma262/#sec-number.parseFloat
-// eslint-disable-next-line es-x/no-number-parsefloat -- required for testing
+// eslint-disable-next-line es/no-number-parsefloat -- required for testing
$({ target: 'Number', stat: true, forced: Number.parseFloat != parseFloat }, {
parseFloat: parseFloat
});
diff --git a/packages/core-js/modules/es.number.parse-int.js b/packages/core-js/modules/es.number.parse-int.js
index f044b826e8e9..7c6773da6287 100644
--- a/packages/core-js/modules/es.number.parse-int.js
+++ b/packages/core-js/modules/es.number.parse-int.js
@@ -3,7 +3,7 @@ var parseInt = require('../internals/number-parse-int');
// `Number.parseInt` method
// https://tc39.es/ecma262/#sec-number.parseint
-// eslint-disable-next-line es-x/no-number-parseint -- required for testing
+// eslint-disable-next-line es/no-number-parseint -- required for testing
$({ target: 'Number', stat: true, forced: Number.parseInt != parseInt }, {
parseInt: parseInt
});
diff --git a/packages/core-js/modules/es.object.assign.js b/packages/core-js/modules/es.object.assign.js
index d6fee7c5355b..f1acd440d07e 100644
--- a/packages/core-js/modules/es.object.assign.js
+++ b/packages/core-js/modules/es.object.assign.js
@@ -3,7 +3,7 @@ var assign = require('../internals/object-assign');
// `Object.assign` method
// https://tc39.es/ecma262/#sec-object.assign
-// eslint-disable-next-line es-x/no-object-assign -- required for testing
+// eslint-disable-next-line es/no-object-assign -- required for testing
$({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign }, {
assign: assign
});
diff --git a/packages/core-js/modules/es.object.define-properties.js b/packages/core-js/modules/es.object.define-properties.js
index d3ea4482249c..f618b5a65188 100644
--- a/packages/core-js/modules/es.object.define-properties.js
+++ b/packages/core-js/modules/es.object.define-properties.js
@@ -4,7 +4,7 @@ var defineProperties = require('../internals/object-define-properties').f;
// `Object.defineProperties` method
// https://tc39.es/ecma262/#sec-object.defineproperties
-// eslint-disable-next-line es-x/no-object-defineproperties -- safe
+// eslint-disable-next-line es/no-object-defineproperties -- safe
$({ target: 'Object', stat: true, forced: Object.defineProperties !== defineProperties, sham: !DESCRIPTORS }, {
defineProperties: defineProperties
});
diff --git a/packages/core-js/modules/es.object.define-property.js b/packages/core-js/modules/es.object.define-property.js
index 26519934e7eb..33b7d21fabdd 100644
--- a/packages/core-js/modules/es.object.define-property.js
+++ b/packages/core-js/modules/es.object.define-property.js
@@ -4,7 +4,7 @@ var defineProperty = require('../internals/object-define-property').f;
// `Object.defineProperty` method
// https://tc39.es/ecma262/#sec-object.defineproperty
-// eslint-disable-next-line es-x/no-object-defineproperty -- safe
+// eslint-disable-next-line es/no-object-defineproperty -- safe
$({ target: 'Object', stat: true, forced: Object.defineProperty !== defineProperty, sham: !DESCRIPTORS }, {
defineProperty: defineProperty
});
diff --git a/packages/core-js/modules/es.object.freeze.js b/packages/core-js/modules/es.object.freeze.js
index bf376bec0c8d..b9fea85024e5 100644
--- a/packages/core-js/modules/es.object.freeze.js
+++ b/packages/core-js/modules/es.object.freeze.js
@@ -4,7 +4,7 @@ var fails = require('../internals/fails');
var isObject = require('../internals/is-object');
var onFreeze = require('../internals/internal-metadata').onFreeze;
-// eslint-disable-next-line es-x/no-object-freeze -- safe
+// eslint-disable-next-line es/no-object-freeze -- safe
var $freeze = Object.freeze;
var FAILS_ON_PRIMITIVES = fails(function () { $freeze(1); });
diff --git a/packages/core-js/modules/es.object.get-own-property-names.js b/packages/core-js/modules/es.object.get-own-property-names.js
index 293bdfa12578..0bf415221ae5 100644
--- a/packages/core-js/modules/es.object.get-own-property-names.js
+++ b/packages/core-js/modules/es.object.get-own-property-names.js
@@ -2,7 +2,7 @@ var $ = require('../internals/export');
var fails = require('../internals/fails');
var getOwnPropertyNames = require('../internals/object-get-own-property-names-external').f;
-// eslint-disable-next-line es-x/no-object-getownpropertynames -- required for testing
+// eslint-disable-next-line es/no-object-getownpropertynames -- required for testing
var FAILS_ON_PRIMITIVES = fails(function () { return !Object.getOwnPropertyNames(1); });
// `Object.getOwnPropertyNames` method
diff --git a/packages/core-js/modules/es.object.is-extensible.js b/packages/core-js/modules/es.object.is-extensible.js
index 15210a4a374d..162327321b5c 100644
--- a/packages/core-js/modules/es.object.is-extensible.js
+++ b/packages/core-js/modules/es.object.is-extensible.js
@@ -3,7 +3,7 @@ var $isExtensible = require('../internals/object-is-extensible');
// `Object.isExtensible` method
// https://tc39.es/ecma262/#sec-object.isextensible
-// eslint-disable-next-line es-x/no-object-isextensible -- safe
+// eslint-disable-next-line es/no-object-isextensible -- safe
$({ target: 'Object', stat: true, forced: Object.isExtensible !== $isExtensible }, {
isExtensible: $isExtensible
});
diff --git a/packages/core-js/modules/es.object.is-frozen.js b/packages/core-js/modules/es.object.is-frozen.js
index aa4e642007a4..f261afa671d9 100644
--- a/packages/core-js/modules/es.object.is-frozen.js
+++ b/packages/core-js/modules/es.object.is-frozen.js
@@ -4,7 +4,7 @@ var isObject = require('../internals/is-object');
var classof = require('../internals/classof-raw');
var ARRAY_BUFFER_NON_EXTENSIBLE = require('../internals/array-buffer-non-extensible');
-// eslint-disable-next-line es-x/no-object-isfrozen -- safe
+// eslint-disable-next-line es/no-object-isfrozen -- safe
var $isFrozen = Object.isFrozen;
var FAILS_ON_PRIMITIVES = fails(function () { $isFrozen(1); });
diff --git a/packages/core-js/modules/es.object.is-sealed.js b/packages/core-js/modules/es.object.is-sealed.js
index cae9a6fe2a16..ea8f146aef19 100644
--- a/packages/core-js/modules/es.object.is-sealed.js
+++ b/packages/core-js/modules/es.object.is-sealed.js
@@ -4,7 +4,7 @@ var isObject = require('../internals/is-object');
var classof = require('../internals/classof-raw');
var ARRAY_BUFFER_NON_EXTENSIBLE = require('../internals/array-buffer-non-extensible');
-// eslint-disable-next-line es-x/no-object-issealed -- safe
+// eslint-disable-next-line es/no-object-issealed -- safe
var $isSealed = Object.isSealed;
var FAILS_ON_PRIMITIVES = fails(function () { $isSealed(1); });
diff --git a/packages/core-js/modules/es.object.prevent-extensions.js b/packages/core-js/modules/es.object.prevent-extensions.js
index c861aa09f3ed..fab864e1bebb 100644
--- a/packages/core-js/modules/es.object.prevent-extensions.js
+++ b/packages/core-js/modules/es.object.prevent-extensions.js
@@ -4,7 +4,7 @@ var onFreeze = require('../internals/internal-metadata').onFreeze;
var FREEZING = require('../internals/freezing');
var fails = require('../internals/fails');
-// eslint-disable-next-line es-x/no-object-preventextensions -- safe
+// eslint-disable-next-line es/no-object-preventextensions -- safe
var $preventExtensions = Object.preventExtensions;
var FAILS_ON_PRIMITIVES = fails(function () { $preventExtensions(1); });
diff --git a/packages/core-js/modules/es.object.proto.js b/packages/core-js/modules/es.object.proto.js
index 11b9de11766f..2ec562750dc6 100644
--- a/packages/core-js/modules/es.object.proto.js
+++ b/packages/core-js/modules/es.object.proto.js
@@ -5,9 +5,9 @@ var isObject = require('../internals/is-object');
var toObject = require('../internals/to-object');
var requireObjectCoercible = require('../internals/require-object-coercible');
-// eslint-disable-next-line es-x/no-object-getprototypeof -- safe
+// eslint-disable-next-line es/no-object-getprototypeof -- safe
var getPrototypeOf = Object.getPrototypeOf;
-// eslint-disable-next-line es-x/no-object-setprototypeof -- safe
+// eslint-disable-next-line es/no-object-setprototypeof -- safe
var setPrototypeOf = Object.setPrototypeOf;
var ObjectPrototype = Object.prototype;
var PROTO = '__proto__';
diff --git a/packages/core-js/modules/es.object.seal.js b/packages/core-js/modules/es.object.seal.js
index 062eacda7949..79d3c83d6cdb 100644
--- a/packages/core-js/modules/es.object.seal.js
+++ b/packages/core-js/modules/es.object.seal.js
@@ -4,7 +4,7 @@ var onFreeze = require('../internals/internal-metadata').onFreeze;
var FREEZING = require('../internals/freezing');
var fails = require('../internals/fails');
-// eslint-disable-next-line es-x/no-object-seal -- safe
+// eslint-disable-next-line es/no-object-seal -- safe
var $seal = Object.seal;
var FAILS_ON_PRIMITIVES = fails(function () { $seal(1); });
diff --git a/packages/core-js/modules/es.reflect.apply.js b/packages/core-js/modules/es.reflect.apply.js
index 9c4e9a591666..0025bcc0b527 100644
--- a/packages/core-js/modules/es.reflect.apply.js
+++ b/packages/core-js/modules/es.reflect.apply.js
@@ -6,7 +6,7 @@ var fails = require('../internals/fails');
// MS Edge argumentsList argument is optional
var OPTIONAL_ARGUMENTS_LIST = !fails(function () {
- // eslint-disable-next-line es-x/no-reflect -- required for testing
+ // eslint-disable-next-line es/no-reflect -- required for testing
Reflect.apply(function () { /* empty */ });
});
diff --git a/packages/core-js/modules/es.reflect.define-property.js b/packages/core-js/modules/es.reflect.define-property.js
index b76d291aea97..03bcd3df51ac 100644
--- a/packages/core-js/modules/es.reflect.define-property.js
+++ b/packages/core-js/modules/es.reflect.define-property.js
@@ -7,7 +7,7 @@ var fails = require('../internals/fails');
// MS Edge has broken Reflect.defineProperty - throwing instead of returning false
var ERROR_INSTEAD_OF_FALSE = fails(function () {
- // eslint-disable-next-line es-x/no-reflect -- required for testing
+ // eslint-disable-next-line es/no-reflect -- required for testing
Reflect.defineProperty(definePropertyModule.f({}, 1, { value: 1 }), 1, { value: 2 });
});
diff --git a/packages/core-js/modules/es.reflect.set.js b/packages/core-js/modules/es.reflect.set.js
index 73d9f613bd3b..87b7d38b3daa 100644
--- a/packages/core-js/modules/es.reflect.set.js
+++ b/packages/core-js/modules/es.reflect.set.js
@@ -40,7 +40,7 @@ function set(target, propertyKey, V /* , receiver */) {
var MS_EDGE_BUG = fails(function () {
var Constructor = function () { /* empty */ };
var object = definePropertyModule.f(new Constructor(), 'a', { configurable: true });
- // eslint-disable-next-line es-x/no-reflect -- required for testing
+ // eslint-disable-next-line es/no-reflect -- required for testing
return Reflect.set(Constructor.prototype, 'a', 1, object) !== false;
});
diff --git a/packages/core-js/modules/es.regexp.flags.js b/packages/core-js/modules/es.regexp.flags.js
index 28f7ad99ed47..6b119ac7b637 100644
--- a/packages/core-js/modules/es.regexp.flags.js
+++ b/packages/core-js/modules/es.regexp.flags.js
@@ -22,7 +22,7 @@ var FORCED = DESCRIPTORS && fails(function () {
var expected = INDICES_SUPPORT ? 'dgimsy' : 'gimsy';
var addGetter = function (key, chr) {
- // eslint-disable-next-line es-x/no-object-defineproperty -- safe
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
Object.defineProperty(O, key, { get: function () {
calls += chr;
return true;
@@ -41,7 +41,7 @@ var FORCED = DESCRIPTORS && fails(function () {
for (var key in pairs) addGetter(key, pairs[key]);
- // eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var result = Object.getOwnPropertyDescriptor(RegExpPrototype, 'flags').get.call(O);
return result !== expected || calls !== expected;
diff --git a/packages/core-js/modules/es.string.at-alternative.js b/packages/core-js/modules/es.string.at-alternative.js
index 2d6c17cfe5ed..6e6c05276de4 100644
--- a/packages/core-js/modules/es.string.at-alternative.js
+++ b/packages/core-js/modules/es.string.at-alternative.js
@@ -9,7 +9,7 @@ var fails = require('../internals/fails');
var charAt = uncurryThis(''.charAt);
var FORCED = fails(function () {
- // eslint-disable-next-line es-x/no-array-string-prototype-at -- safe
+ // eslint-disable-next-line es/no-array-string-prototype-at -- safe
return '𠮷'.at(-2) !== '\uD842';
});
diff --git a/packages/core-js/modules/es.string.ends-with.js b/packages/core-js/modules/es.string.ends-with.js
index 2c6674b15bec..ceea69d87cd0 100644
--- a/packages/core-js/modules/es.string.ends-with.js
+++ b/packages/core-js/modules/es.string.ends-with.js
@@ -9,7 +9,7 @@ var requireObjectCoercible = require('../internals/require-object-coercible');
var correctIsRegExpLogic = require('../internals/correct-is-regexp-logic');
var IS_PURE = require('../internals/is-pure');
-// eslint-disable-next-line es-x/no-string-prototype-endswith -- safe
+// eslint-disable-next-line es/no-string-prototype-endswith -- safe
var nativeEndsWith = uncurryThis(''.endsWith);
var slice = uncurryThis(''.slice);
var min = Math.min;
diff --git a/packages/core-js/modules/es.string.from-code-point.js b/packages/core-js/modules/es.string.from-code-point.js
index 0183789b23b8..9dc217a84b26 100644
--- a/packages/core-js/modules/es.string.from-code-point.js
+++ b/packages/core-js/modules/es.string.from-code-point.js
@@ -4,7 +4,7 @@ var toAbsoluteIndex = require('../internals/to-absolute-index');
var $RangeError = RangeError;
var fromCharCode = String.fromCharCode;
-// eslint-disable-next-line es-x/no-string-fromcodepoint -- required for testing
+// eslint-disable-next-line es/no-string-fromcodepoint -- required for testing
var $fromCodePoint = String.fromCodePoint;
var join = uncurryThis([].join);
diff --git a/packages/core-js/modules/es.string.match-all.js b/packages/core-js/modules/es.string.match-all.js
index ac097561968b..cd25d901a70b 100644
--- a/packages/core-js/modules/es.string.match-all.js
+++ b/packages/core-js/modules/es.string.match-all.js
@@ -1,5 +1,5 @@
'use strict';
-/* eslint-disable es-x/no-string-prototype-matchall -- safe */
+/* eslint-disable es/no-string-prototype-matchall -- safe */
var $ = require('../internals/export');
var call = require('../internals/function-call');
var uncurryThis = require('../internals/function-uncurry-this');
diff --git a/packages/core-js/modules/es.string.starts-with.js b/packages/core-js/modules/es.string.starts-with.js
index 2c149eb976ef..533be0aedd0e 100644
--- a/packages/core-js/modules/es.string.starts-with.js
+++ b/packages/core-js/modules/es.string.starts-with.js
@@ -9,7 +9,7 @@ var requireObjectCoercible = require('../internals/require-object-coercible');
var correctIsRegExpLogic = require('../internals/correct-is-regexp-logic');
var IS_PURE = require('../internals/is-pure');
-// eslint-disable-next-line es-x/no-string-prototype-startswith -- safe
+// eslint-disable-next-line es/no-string-prototype-startswith -- safe
var nativeStartsWith = uncurryThis(''.startsWith);
var stringSlice = uncurryThis(''.slice);
var min = Math.min;
diff --git a/packages/core-js/modules/es.string.substr.js b/packages/core-js/modules/es.string.substr.js
index 971289b20dbd..2f7c8037bd41 100644
--- a/packages/core-js/modules/es.string.substr.js
+++ b/packages/core-js/modules/es.string.substr.js
@@ -9,7 +9,7 @@ var stringSlice = uncurryThis(''.slice);
var max = Math.max;
var min = Math.min;
-// eslint-disable-next-line unicorn/prefer-string-slice, es-x/no-string-prototype-substr -- required for testing
+// eslint-disable-next-line unicorn/prefer-string-slice, es/no-string-prototype-substr -- required for testing
var FORCED = !''.substr || 'ab'.substr(-1) !== 'b';
// `String.prototype.substr` method
diff --git a/packages/core-js/modules/es.string.trim-end.js b/packages/core-js/modules/es.string.trim-end.js
index b8e4187d3be1..7800803ec7e1 100644
--- a/packages/core-js/modules/es.string.trim-end.js
+++ b/packages/core-js/modules/es.string.trim-end.js
@@ -5,7 +5,7 @@ var trimEnd = require('../internals/string-trim-end');
// `String.prototype.trimEnd` method
// https://tc39.es/ecma262/#sec-string.prototype.trimend
-// eslint-disable-next-line es-x/no-string-prototype-trimstart-trimend -- safe
+// eslint-disable-next-line es/no-string-prototype-trimstart-trimend -- safe
$({ target: 'String', proto: true, name: 'trimEnd', forced: ''.trimEnd !== trimEnd }, {
trimEnd: trimEnd
});
diff --git a/packages/core-js/modules/es.string.trim-left.js b/packages/core-js/modules/es.string.trim-left.js
index 9dab08b3b173..43bbe9abd5ec 100644
--- a/packages/core-js/modules/es.string.trim-left.js
+++ b/packages/core-js/modules/es.string.trim-left.js
@@ -3,7 +3,7 @@ var trimStart = require('../internals/string-trim-start');
// `String.prototype.trimLeft` method
// https://tc39.es/ecma262/#sec-string.prototype.trimleft
-// eslint-disable-next-line es-x/no-string-prototype-trimleft-trimright -- safe
+// eslint-disable-next-line es/no-string-prototype-trimleft-trimright -- safe
$({ target: 'String', proto: true, name: 'trimStart', forced: ''.trimLeft !== trimStart }, {
trimLeft: trimStart
});
diff --git a/packages/core-js/modules/es.string.trim-right.js b/packages/core-js/modules/es.string.trim-right.js
index 9164acb7e5a5..a7f103d785b0 100644
--- a/packages/core-js/modules/es.string.trim-right.js
+++ b/packages/core-js/modules/es.string.trim-right.js
@@ -3,7 +3,7 @@ var trimEnd = require('../internals/string-trim-end');
// `String.prototype.trimRight` method
// https://tc39.es/ecma262/#sec-string.prototype.trimend
-// eslint-disable-next-line es-x/no-string-prototype-trimleft-trimright -- safe
+// eslint-disable-next-line es/no-string-prototype-trimleft-trimright -- safe
$({ target: 'String', proto: true, name: 'trimEnd', forced: ''.trimRight !== trimEnd }, {
trimRight: trimEnd
});
diff --git a/packages/core-js/modules/es.string.trim-start.js b/packages/core-js/modules/es.string.trim-start.js
index 40dcdc926cfb..58d4dcc549fb 100644
--- a/packages/core-js/modules/es.string.trim-start.js
+++ b/packages/core-js/modules/es.string.trim-start.js
@@ -5,7 +5,7 @@ var trimStart = require('../internals/string-trim-start');
// `String.prototype.trimStart` method
// https://tc39.es/ecma262/#sec-string.prototype.trimstart
-// eslint-disable-next-line es-x/no-string-prototype-trimstart-trimend -- safe
+// eslint-disable-next-line es/no-string-prototype-trimstart-trimend -- safe
$({ target: 'String', proto: true, name: 'trimStart', forced: ''.trimStart !== trimStart }, {
trimStart: trimStart
});
diff --git a/packages/core-js/modules/es.typed-array.fill.js b/packages/core-js/modules/es.typed-array.fill.js
index 9ca93ecc1ce0..3fa8a878d2a1 100644
--- a/packages/core-js/modules/es.typed-array.fill.js
+++ b/packages/core-js/modules/es.typed-array.fill.js
@@ -14,7 +14,7 @@ var slice = uncurryThis(''.slice);
// V8 ~ Chrome < 59, Safari < 14.1, FF < 55, Edge <=18
var CONVERSION_BUG = fails(function () {
var count = 0;
- // eslint-disable-next-line es-x/no-typed-arrays -- safe
+ // eslint-disable-next-line es/no-typed-arrays -- safe
new Int8Array(2).fill({ valueOf: function () { return count++; } });
return count !== 1;
});
diff --git a/packages/core-js/modules/es.typed-array.set.js b/packages/core-js/modules/es.typed-array.set.js
index 3965c8791ccb..768c4521571b 100644
--- a/packages/core-js/modules/es.typed-array.set.js
+++ b/packages/core-js/modules/es.typed-array.set.js
@@ -15,7 +15,7 @@ var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var WORKS_WITH_OBJECTS_AND_GEERIC_ON_TYPED_ARRAYS = !fails(function () {
- // eslint-disable-next-line es-x/no-typed-arrays -- required for testing
+ // eslint-disable-next-line es/no-typed-arrays -- required for testing
var array = new Uint8ClampedArray(2);
call($set, array, { length: 1, 0: 3 }, 1);
return array[1] !== 3;
diff --git a/packages/core-js/modules/es.typed-array.slice.js b/packages/core-js/modules/es.typed-array.slice.js
index a5cc8fff0cf4..33dc2b9db8c1 100644
--- a/packages/core-js/modules/es.typed-array.slice.js
+++ b/packages/core-js/modules/es.typed-array.slice.js
@@ -8,7 +8,7 @@ var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var FORCED = fails(function () {
- // eslint-disable-next-line es-x/no-typed-arrays -- required for testing
+ // eslint-disable-next-line es/no-typed-arrays -- required for testing
new Int8Array(1).slice();
});
diff --git a/packages/core-js/modules/esnext.array.is-template-object.js b/packages/core-js/modules/esnext.array.is-template-object.js
index 6cddf8a90482..e5ef6af0ed04 100644
--- a/packages/core-js/modules/esnext.array.is-template-object.js
+++ b/packages/core-js/modules/esnext.array.is-template-object.js
@@ -1,7 +1,7 @@
var $ = require('../internals/export');
var isArray = require('../internals/is-array');
-// eslint-disable-next-line es-x/no-object-isfrozen -- safe
+// eslint-disable-next-line es/no-object-isfrozen -- safe
var isFrozen = Object.isFrozen;
var isFrozenStringArray = function (array, allowUndefined) {
diff --git a/packages/core-js/modules/esnext.bigint.range.js b/packages/core-js/modules/esnext.bigint.range.js
index c1475a74d3ff..93625a6f0ee3 100644
--- a/packages/core-js/modules/esnext.bigint.range.js
+++ b/packages/core-js/modules/esnext.bigint.range.js
@@ -1,5 +1,5 @@
'use strict';
-/* eslint-disable es-x/no-bigint -- safe */
+/* eslint-disable es/no-bigint -- safe */
var $ = require('../internals/export');
var NumericRangeIterator = require('../internals/numeric-range-iterator');
diff --git a/packages/core-js/modules/esnext.function.is-callable.js b/packages/core-js/modules/esnext.function.is-callable.js
index 92fac56bec0d..466699915446 100644
--- a/packages/core-js/modules/esnext.function.is-callable.js
+++ b/packages/core-js/modules/esnext.function.is-callable.js
@@ -5,7 +5,7 @@ var inspectSource = require('../internals/inspect-source');
var hasOwn = require('../internals/has-own-property');
var DESCRIPTORS = require('../internals/descriptors');
-// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
var classRegExp = /^\s*class\b/;
var exec = uncurryThis(classRegExp.exec);
diff --git a/packages/core-js/modules/esnext.typed-array.to-spliced.js b/packages/core-js/modules/esnext.typed-array.to-spliced.js
index 1be800dbaf5d..9ed5450dd1db 100644
--- a/packages/core-js/modules/esnext.typed-array.to-spliced.js
+++ b/packages/core-js/modules/esnext.typed-array.to-spliced.js
@@ -16,7 +16,7 @@ var min = Math.min;
// some early implementations, like WebKit, does not follow the final semantic
var PROPER_ORDER = !fails(function () {
- // eslint-disable-next-line es-x/no-typed-arrays -- required for testing
+ // eslint-disable-next-line es/no-typed-arrays -- required for testing
var array = new Int8Array([1]);
var spliced = array.toSpliced(1, 0, {
diff --git a/packages/core-js/modules/esnext.typed-array.with.js b/packages/core-js/modules/esnext.typed-array.with.js
index e2cab009bde4..79146cd77385 100644
--- a/packages/core-js/modules/esnext.typed-array.with.js
+++ b/packages/core-js/modules/esnext.typed-array.with.js
@@ -11,7 +11,7 @@ var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var PROPER_ORDER = !!function () {
try {
- // eslint-disable-next-line no-throw-literal, es-x/no-typed-arrays -- required for testing
+ // eslint-disable-next-line no-throw-literal, es/no-typed-arrays -- required for testing
new Int8Array(1)['with'](2, { valueOf: function () { throw 8; } });
} catch (error) {
// some early implementations, like WebKit, does not follow the final semantic
diff --git a/packages/core-js/modules/web.dom-exception.constructor.js b/packages/core-js/modules/web.dom-exception.constructor.js
index 037f6582a16b..69536b74307c 100644
--- a/packages/core-js/modules/web.dom-exception.constructor.js
+++ b/packages/core-js/modules/web.dom-exception.constructor.js
@@ -27,7 +27,7 @@ var NativeDOMException = getBuiltIn(DOM_EXCEPTION) || (function () {
try {
// NodeJS < 15.0 does not expose `MessageChannel` to global
var MessageChannel = getBuiltIn('MessageChannel') || tryNodeRequire('worker_threads').MessageChannel;
- // eslint-disable-next-line es-x/no-weak-map, unicorn/require-post-message-target-origin -- safe
+ // eslint-disable-next-line es/no-weak-map, unicorn/require-post-message-target-origin -- safe
new MessageChannel().port1.postMessage(new WeakMap());
} catch (error) {
if (error.name == DATA_CLONE_ERR && error.code == 25) return error.constructor;
diff --git a/packages/core-js/modules/web.dom-exception.stack.js b/packages/core-js/modules/web.dom-exception.stack.js
index bde589758b96..7e67e6fd18de 100644
--- a/packages/core-js/modules/web.dom-exception.stack.js
+++ b/packages/core-js/modules/web.dom-exception.stack.js
@@ -35,7 +35,7 @@ var DOMExceptionPrototype = $DOMException.prototype = NativeDOMException.prototy
var ERROR_HAS_STACK = 'stack' in Error(DOM_EXCEPTION);
var DOM_EXCEPTION_HAS_STACK = 'stack' in new NativeDOMException(1, 2);
-// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var descriptor = NativeDOMException && DESCRIPTORS && Object.getOwnPropertyDescriptor(global, DOM_EXCEPTION);
// Bun ~ 0.1.1 DOMException have incorrect descriptor and we can't redefine it
diff --git a/packages/core-js/modules/web.url-search-params.constructor.js b/packages/core-js/modules/web.url-search-params.constructor.js
index 0f1a4ae050e9..be5a155b55ab 100644
--- a/packages/core-js/modules/web.url-search-params.constructor.js
+++ b/packages/core-js/modules/web.url-search-params.constructor.js
@@ -34,7 +34,7 @@ var URL_SEARCH_PARAMS_ITERATOR = URL_SEARCH_PARAMS + 'Iterator';
var setInternalState = InternalStateModule.set;
var getInternalParamsState = InternalStateModule.getterFor(URL_SEARCH_PARAMS);
var getInternalIteratorState = InternalStateModule.getterFor(URL_SEARCH_PARAMS_ITERATOR);
-// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
// Avoid NodeJS experimental warning
diff --git a/tests/commonjs.mjs b/tests/commonjs.mjs
index 73db2c4cabcf..b47bb39d2e43 100644
--- a/tests/commonjs.mjs
+++ b/tests/commonjs.mjs
@@ -1,4 +1,4 @@
-/* eslint-disable import/no-dynamic-require, n/global-require -- required */
+/* eslint-disable import/no-dynamic-require, node/global-require -- required */
import { ok } from 'assert';
const entries = require('core-js-compat/entries');
diff --git a/tests/helpers/constants.js b/tests/helpers/constants.js
index 01b2a5cdb09f..2e0f00c88291 100644
--- a/tests/helpers/constants.js
+++ b/tests/helpers/constants.js
@@ -41,7 +41,7 @@ for (const name of ['BigInt64Array', 'BigUint64Array']) if (GLOBAL[name]) TYPED_
name,
TypedArray: GLOBAL[name],
bytes: 8,
- // eslint-disable-next-line es-x/no-bigint -- safe
+ // eslint-disable-next-line es/no-bigint -- safe
$: BigInt,
});
diff --git a/tests/pure/es.array.sort.js b/tests/pure/es.array.sort.js
index 3bbc92dfd25a..3860d17757ba 100644
--- a/tests/pure/es.array.sort.js
+++ b/tests/pure/es.array.sort.js
@@ -112,7 +112,7 @@ QUnit.test('Array#sort', assert => {
assert.same(result, 'DGBEFHACIJK', 'stable #2');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => sort([Symbol(1), Symbol(2)]), 'w/o cmp throws on symbols');
}
diff --git a/tests/pure/es.escape.js b/tests/pure/es.escape.js
index 4c576aedbc3a..d984dd6c95b6 100644
--- a/tests/pure/es.escape.js
+++ b/tests/pure/es.escape.js
@@ -7,7 +7,7 @@ QUnit.test('escape', assert => {
assert.same(escape(null), 'null');
assert.same(escape(undefined), 'undefined');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => escape(Symbol()), 'throws on symbol argument');
}
diff --git a/tests/pure/es.number.parse-float.js b/tests/pure/es.number.parse-float.js
index 60384333bd77..484060523cf8 100644
--- a/tests/pure/es.number.parse-float.js
+++ b/tests/pure/es.number.parse-float.js
@@ -16,7 +16,7 @@ QUnit.test('Number.parseFloat', assert => {
assert.same(parseFloat(null), NaN);
assert.same(parseFloat(undefined), NaN);
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => parseFloat(Symbol()), 'throws on symbol argument');
assert.throws(() => parseFloat(Object(Symbol())), 'throws on boxed symbol argument');
diff --git a/tests/pure/es.number.parse-int.js b/tests/pure/es.number.parse-int.js
index 8aa34b81322b..d47a2f31213d 100644
--- a/tests/pure/es.number.parse-int.js
+++ b/tests/pure/es.number.parse-int.js
@@ -33,7 +33,7 @@ QUnit.test('Number.parseInt', assert => {
assert.same(parseInt(null), NaN);
assert.same(parseInt(undefined), NaN);
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => parseInt(Symbol()), 'throws on symbol argument');
assert.throws(() => parseInt(Object(Symbol())), 'throws on boxed symbol argument');
diff --git a/tests/pure/es.parse-float.js b/tests/pure/es.parse-float.js
index ba60490ddee9..e5acc4b569b0 100644
--- a/tests/pure/es.parse-float.js
+++ b/tests/pure/es.parse-float.js
@@ -15,7 +15,7 @@ QUnit.test('parseFloat', assert => {
assert.same(parseFloat(null), NaN);
assert.same(parseFloat(undefined), NaN);
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => parseFloat(Symbol()), 'throws on symbol argument');
assert.throws(() => parseFloat(Object(Symbol())), 'throws on boxed symbol argument');
diff --git a/tests/pure/es.parse-int.js b/tests/pure/es.parse-int.js
index 74722ba2b7d6..be01c2786822 100644
--- a/tests/pure/es.parse-int.js
+++ b/tests/pure/es.parse-int.js
@@ -32,7 +32,7 @@ QUnit.test('parseInt', assert => {
assert.same(parseInt(null), NaN);
assert.same(parseInt(undefined), NaN);
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => parseInt(Symbol()), 'throws on symbol argument');
assert.throws(() => parseInt(Object(Symbol())), 'throws on boxed symbol argument');
diff --git a/tests/pure/es.promise.constructor.js b/tests/pure/es.promise.constructor.js
index fef83a2e0caa..ae99d5f4fecd 100644
--- a/tests/pure/es.promise.constructor.js
+++ b/tests/pure/es.promise.constructor.js
@@ -44,7 +44,7 @@ if (DESCRIPTORS) QUnit.test('Promise operations order', assert => {
const promise2 = new Promise(resolve => {
$resolve2 = resolve;
});
- // eslint-disable-next-line es-x/no-object-defineproperty, unicorn/no-thenable -- required for testing
+ // eslint-disable-next-line es/no-object-defineproperty, unicorn/no-thenable -- required for testing
$resolve2(Object.defineProperty({}, 'then', {
get() {
result += 'D';
diff --git a/tests/pure/es.string.anchor.js b/tests/pure/es.string.anchor.js
index 2a30180486aa..b4a466a24786 100644
--- a/tests/pure/es.string.anchor.js
+++ b/tests/pure/es.string.anchor.js
@@ -5,7 +5,7 @@ QUnit.test('String#anchor', assert => {
assert.same(anchor('a', 'b'), 'a', 'lower case');
assert.same(anchor('a', '"'), 'a', 'escape quotes');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => anchor(Symbol(), 'b'), 'throws on symbol context');
assert.throws(() => anchor('a', Symbol()), 'throws on symbol argument');
diff --git a/tests/pure/es.string.big.js b/tests/pure/es.string.big.js
index cb3fdcdc5919..bdb794badb02 100644
--- a/tests/pure/es.string.big.js
+++ b/tests/pure/es.string.big.js
@@ -4,7 +4,7 @@ QUnit.test('String#big', assert => {
assert.isFunction(big);
assert.same(big('a'), 'a', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => big(Symbol()), 'throws on symbol argument');
}
diff --git a/tests/pure/es.string.blink.js b/tests/pure/es.string.blink.js
index 8e62401fabb3..b3fe96378437 100644
--- a/tests/pure/es.string.blink.js
+++ b/tests/pure/es.string.blink.js
@@ -4,7 +4,7 @@ QUnit.test('String#blink', assert => {
assert.isFunction(blink);
assert.same(blink('a'), '', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => blink(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.bold.js b/tests/pure/es.string.bold.js
index 3c86f3a73bac..a0d938b0d67d 100644
--- a/tests/pure/es.string.bold.js
+++ b/tests/pure/es.string.bold.js
@@ -4,7 +4,7 @@ QUnit.test('String#bold', assert => {
assert.isFunction(bold);
assert.same(bold('a'), 'a', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => bold(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.code-point-at.js b/tests/pure/es.string.code-point-at.js
index 48341819e366..72d4295c7efc 100644
--- a/tests/pure/es.string.code-point-at.js
+++ b/tests/pure/es.string.code-point-at.js
@@ -54,7 +54,7 @@ QUnit.test('String#codePointAt', assert => {
assert.same(codePointAt('\uDF06abc', null), 0xDF06);
assert.same(codePointAt('\uDF06abc', undefined), 0xDF06);
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => codePointAt(Symbol(), 1), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.fixed.js b/tests/pure/es.string.fixed.js
index 180a92c56242..1851da4c834b 100644
--- a/tests/pure/es.string.fixed.js
+++ b/tests/pure/es.string.fixed.js
@@ -4,7 +4,7 @@ QUnit.test('String#fixed', assert => {
assert.isFunction(fixed);
assert.same(fixed('a'), 'a', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => fixed(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.fontcolor.js b/tests/pure/es.string.fontcolor.js
index 7a13edfe1f28..9a037f291cc9 100644
--- a/tests/pure/es.string.fontcolor.js
+++ b/tests/pure/es.string.fontcolor.js
@@ -5,7 +5,7 @@ QUnit.test('String#fontcolor', assert => {
assert.same(fontcolor('a', 'b'), 'a', 'lower case');
assert.same(fontcolor('a', '"'), 'a', 'escape quotes');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => fontcolor(Symbol(), 'b'), 'throws on symbol context');
assert.throws(() => fontcolor('a', Symbol()), 'throws on symbol argument');
diff --git a/tests/pure/es.string.fontsize.js b/tests/pure/es.string.fontsize.js
index d49539c545c7..524b59fe9954 100644
--- a/tests/pure/es.string.fontsize.js
+++ b/tests/pure/es.string.fontsize.js
@@ -5,7 +5,7 @@ QUnit.test('String#fontsize', assert => {
assert.same(fontsize('a', 'b'), 'a', 'lower case');
assert.same(fontsize('a', '"'), 'a', 'escape quotes');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => fontsize(Symbol(), 'b'), 'throws on symbol context');
assert.throws(() => fontsize('a', Symbol()), 'throws on symbol argument');
diff --git a/tests/pure/es.string.italics.js b/tests/pure/es.string.italics.js
index 86303c1906d8..2682922f5cd5 100644
--- a/tests/pure/es.string.italics.js
+++ b/tests/pure/es.string.italics.js
@@ -4,7 +4,7 @@ QUnit.test('String#italics', assert => {
assert.isFunction(italics);
assert.same(italics('a'), 'a', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => italics(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.link.js b/tests/pure/es.string.link.js
index b801d2c314d9..87267efe1dcd 100644
--- a/tests/pure/es.string.link.js
+++ b/tests/pure/es.string.link.js
@@ -5,7 +5,7 @@ QUnit.test('String#link', assert => {
assert.same(link('a', 'b'), 'a', 'lower case');
assert.same(link('a', '"'), 'a', 'escape quotes');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => link(Symbol(), 'b'), 'throws on symbol context');
assert.throws(() => link('a', Symbol()), 'throws on symbol argument');
diff --git a/tests/pure/es.string.raw.js b/tests/pure/es.string.raw.js
index 0e26dcc5bd0a..4a2322c8276a 100644
--- a/tests/pure/es.string.raw.js
+++ b/tests/pure/es.string.raw.js
@@ -10,7 +10,7 @@ QUnit.test('String.raw', assert => {
assert.same(raw({ raw: 'test' }, 0, 1, 2), 't0e1s2t', 'raw is string');
assert.same(raw({ raw: 'test' }, 0), 't0est', 'lacks substituting');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => raw({ raw: [Symbol()] }, 0), TypeError, 'throws on symbol #1');
assert.throws(() => raw({ raw: 'test' }, Symbol()), TypeError, 'throws on symbol #2');
diff --git a/tests/pure/es.string.repeat.js b/tests/pure/es.string.repeat.js
index 9167edcce1fa..d7a61d66a1a3 100644
--- a/tests/pure/es.string.repeat.js
+++ b/tests/pure/es.string.repeat.js
@@ -9,7 +9,7 @@ QUnit.test('String#repeat', assert => {
assert.throws(() => repeat('qwe', -1), RangeError);
assert.throws(() => repeat('qwe', Infinity), RangeError);
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => repeat(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.small.js b/tests/pure/es.string.small.js
index 88a3fb4da366..c2302824f859 100644
--- a/tests/pure/es.string.small.js
+++ b/tests/pure/es.string.small.js
@@ -4,7 +4,7 @@ QUnit.test('String#small', assert => {
assert.isFunction(small);
assert.same(small('a'), 'a', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => small(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.strike.js b/tests/pure/es.string.strike.js
index fcb9df0da475..576638b4ecf6 100644
--- a/tests/pure/es.string.strike.js
+++ b/tests/pure/es.string.strike.js
@@ -4,7 +4,7 @@ QUnit.test('String#strike', assert => {
assert.isFunction(strike);
assert.same(strike('a'), 'a', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => strike(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.sub.js b/tests/pure/es.string.sub.js
index bd8877ef538a..1bcb53a28027 100644
--- a/tests/pure/es.string.sub.js
+++ b/tests/pure/es.string.sub.js
@@ -4,7 +4,7 @@ QUnit.test('String#sub', assert => {
assert.isFunction(sub);
assert.same(sub('a'), 'a', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => sub(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.substr.js b/tests/pure/es.string.substr.js
index e608d6d075e3..6ea8f010233a 100644
--- a/tests/pure/es.string.substr.js
+++ b/tests/pure/es.string.substr.js
@@ -8,7 +8,7 @@ QUnit.test('String#substr', assert => {
assert.same(substr('ab', -1), 'b');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => substr(Symbol(), 1, 3), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.sup.js b/tests/pure/es.string.sup.js
index 6bc5bfaef314..a677c05f64eb 100644
--- a/tests/pure/es.string.sup.js
+++ b/tests/pure/es.string.sup.js
@@ -4,7 +4,7 @@ QUnit.test('String#sup', assert => {
assert.isFunction(sup);
assert.same(sup('a'), 'a', 'lower case');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => sup(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.string.trim.js b/tests/pure/es.string.trim.js
index 5aceb865628e..c9da0ea8dab8 100644
--- a/tests/pure/es.string.trim.js
+++ b/tests/pure/es.string.trim.js
@@ -8,7 +8,7 @@ QUnit.test('String#trim', assert => {
assert.same(trim(WHITESPACES), '', 'removes all whitespaces');
assert.same(trim('\u200B\u0085'), '\u200B\u0085', "shouldn't remove this symbols");
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => trim(Symbol()), 'throws on symbol context');
}
diff --git a/tests/pure/es.unescape.js b/tests/pure/es.unescape.js
index e58d683b67b4..3f6834e8c214 100644
--- a/tests/pure/es.unescape.js
+++ b/tests/pure/es.unescape.js
@@ -8,7 +8,7 @@ QUnit.test('unescape', assert => {
assert.same(unescape(null), 'null');
assert.same(unescape(undefined), 'undefined');
- /* eslint-disable es-x/no-symbol -- safe */
+ /* eslint-disable es/no-symbol -- safe */
if (typeof Symbol == 'function') {
assert.throws(() => unescape(Symbol()), 'throws on symbol argument');
}
diff --git a/tests/pure/esnext.bigint.range.js b/tests/pure/esnext.bigint.range.js
index 6507ec35586a..014d4ac2a5c0 100644
--- a/tests/pure/esnext.bigint.range.js
+++ b/tests/pure/esnext.bigint.range.js
@@ -1,4 +1,4 @@
-/* eslint-disable es-x/no-bigint -- safe */
+/* eslint-disable es/no-bigint -- safe */
import from from 'core-js-pure/es/array/from';
import range from 'core-js-pure/full/bigint/range';
@@ -48,7 +48,7 @@ if (typeof BigInt == 'function') QUnit.test('BigInt.range', assert => {
assert.true(iterator.inclusive);
iterator = range(BigInt(0), BigInt(5));
- // eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
assert.throws(() => Object.getOwnPropertyDescriptor(iterator, 'start').call({}), TypeError);
assert.throws(() => range(Infinity, BigInt(10), BigInt(0)), TypeError);
diff --git a/tests/pure/esnext.number.range.js b/tests/pure/esnext.number.range.js
index 57e9dddf65a8..bc593066caa9 100644
--- a/tests/pure/esnext.number.range.js
+++ b/tests/pure/esnext.number.range.js
@@ -57,7 +57,7 @@ QUnit.test('range', assert => {
assert.true(iterator.inclusive);
iterator = range(0, 5);
- // eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
assert.throws(() => Object.getOwnPropertyDescriptor(iterator, 'start').call({}), TypeError);
assert.throws(() => range(Infinity, 10, 0), RangeError);
diff --git a/tests/pure/web.structured-clone.js b/tests/pure/web.structured-clone.js
index 487b6898775c..cf6cd451ed03 100644
--- a/tests/pure/web.structured-clone.js
+++ b/tests/pure/web.structured-clone.js
@@ -1,6 +1,6 @@
// Originally from: https://github.com/web-platform-tests/wpt/blob/4b35e758e2fc4225368304b02bcec9133965fd1a/IndexedDB/structured-clone.any.js
// Copyright © web-platform-tests contributors. Available under the 3-Clause BSD License.
-/* eslint-disable es-x/no-typed-arrays -- safe */
+/* eslint-disable es/no-typed-arrays -- safe */
import { GLOBAL, NODE } from '../helpers/constants';
import { fromSource } from '../helpers/helpers';
diff --git a/tests/pure/web.url.js b/tests/pure/web.url.js
index f7b0ebb786f8..1e1cc5893f29 100644
--- a/tests/pure/web.url.js
+++ b/tests/pure/web.url.js
@@ -1,4 +1,4 @@
-/* eslint-disable es-x/no-object-getownpropertydescriptor, unicorn/relative-url-style -- required for testing */
+/* eslint-disable es/no-object-getownpropertydescriptor, unicorn/relative-url-style -- required for testing */
import { DESCRIPTORS, NODE } from '../helpers/constants';
import urlTestData from '../wpt-url-resources/urltestdata';
import settersTestData from '../wpt-url-resources/setters';
diff --git a/tests/tests/esnext.bigint.range.js b/tests/tests/esnext.bigint.range.js
index 2e2259e26bb2..699f4ce1232a 100644
--- a/tests/tests/esnext.bigint.range.js
+++ b/tests/tests/esnext.bigint.range.js
@@ -1,4 +1,4 @@
-/* eslint-disable es-x/no-bigint -- safe */
+/* eslint-disable es/no-bigint -- safe */
if (typeof BigInt == 'function') QUnit.test('BigInt.range', assert => {
const { range } = BigInt;
const { from } = Array;
diff --git a/tests/worker/runner.js b/tests/worker/runner.js
index 85a7892fe778..8af0dac97302 100644
--- a/tests/worker/runner.js
+++ b/tests/worker/runner.js
@@ -7,7 +7,7 @@ setImmediate(function () {
postMessage('setImmediate');
});
-// eslint-disable-next-line es-x/no-promise -- safe
+// eslint-disable-next-line es/no-promise -- safe
Promise.resolve().then(function () {
postMessage('Promise.resolve');
});