es-check 9.6.0 → 9.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,132 +1,68 @@
1
- const POLYFILLABLE_FEATURES = new Set([
2
- "Array.from",
3
- "Array.of",
4
- "Array.prototype.find",
5
- "Array.prototype.findIndex",
6
- "Array.prototype.includes",
7
- "Array.prototype.at",
8
- "Array.prototype.findLast",
9
- "Array.prototype.findLastIndex",
10
- "Array.prototype.toSorted",
11
- "Array.prototype.toReversed",
12
- "Array.prototype.with",
13
- "Array.prototype.flatMap",
14
- "Array.prototype.flat",
15
- "ArrayToSorted",
16
- "ArrayToReversed",
17
- "ArrayWith",
1
+ /**
2
+ * Generated by scripts/generate/polyfills/core.mjs — do not edit manually.
3
+ *
4
+ * These values use es-check's internal feature names (e.g. "ArrayToSorted"),
5
+ * not core-js module names (e.g. "es.array.to-sorted"). Core-js module names
6
+ * cannot be used directly because es-check matches features against its own
7
+ * ES_FEATURES keys, which follow PascalCase naming derived from acorn AST
8
+ * detection. The generation script bridges the two naming schemes by converting
9
+ * core-js modules to es-check feature names and intersecting with ES_FEATURES.
10
+ */
11
+ const coreJsPolyfillable = new Set([
12
+ "ArrayBufferTransfer",
13
+ "ArrayBufferTransferToFixedLength",
18
14
  "ArrayFindLast",
19
15
  "ArrayFindLastIndex",
20
- "ArrayAt",
21
- "String.prototype.includes",
22
- "String.prototype.startsWith",
23
- "String.prototype.endsWith",
24
- "String.prototype.repeat",
25
- "String.prototype.padStart",
26
- "String.prototype.padEnd",
27
- "String.prototype.trimStart",
28
- "String.prototype.trimEnd",
29
- "String.prototype.replaceAll",
30
- "String.prototype.matchAll",
31
- "String.prototype.at",
32
- "StringReplaceAll",
33
- "StringMatchAll",
34
- "StringAt",
35
- "Object.assign",
36
- "Object.keys",
37
- "Object.values",
38
- "Object.entries",
39
- "Object.fromEntries",
40
- "Object.hasOwn",
41
- "ObjectHasOwn",
42
- "Promise.resolve",
43
- "Promise.reject",
44
- "Promise.all",
45
- "Promise.race",
46
- "Promise.allSettled",
47
- "Promise.any",
48
- "PromiseAny",
49
- "PromiseAllSettled",
50
- "Map",
51
- "Set",
52
- "WeakMap",
53
- "WeakSet",
54
- "Symbol",
55
- "Symbol.iterator",
56
- "Symbol.asyncIterator",
57
- "globalThis",
58
- "GlobalThis",
59
- "Number.isNaN",
60
- "Number.isFinite",
61
- "Number.isInteger",
62
- "Number.isSafeInteger",
63
- "Number.parseFloat",
64
- "Number.parseInt",
65
- "Math.trunc",
66
- "Math.sign",
67
- "Math.cbrt",
68
- "Math.hypot",
69
- "RegExp.prototype.flags",
70
- ]);
71
-
72
- const CORE_JS_POLYFILLABLE = new Set([
73
- "Array.from",
74
- "Array.of",
75
- "Array.prototype.find",
76
- "Array.prototype.findIndex",
77
- "Array.prototype.includes",
78
- "Array.prototype.at",
79
- "Array.prototype.findLast",
80
- "Array.prototype.findLastIndex",
81
- "Array.prototype.toSorted",
82
- "Array.prototype.toReversed",
83
- "Array.prototype.with",
84
- "ArrayToSorted",
16
+ "ArrayFlat",
17
+ "ArrayFlatMap",
18
+ "ArrayFromAsync",
19
+ "ArrayPrototypeAt",
20
+ "ArrayPrototypeIncludes",
85
21
  "ArrayToReversed",
22
+ "ArrayToSorted",
23
+ "ArrayToSpliced",
86
24
  "ArrayWith",
87
- "ArrayFindLast",
88
- "ArrayFindLastIndex",
89
- "ArrayAt",
90
- "String.prototype.includes",
91
- "String.prototype.startsWith",
92
- "String.prototype.endsWith",
93
- "String.prototype.repeat",
94
- "String.prototype.padStart",
95
- "String.prototype.padEnd",
96
- "String.prototype.trimStart",
97
- "String.prototype.trimEnd",
98
- "String.prototype.replaceAll",
99
- "String.prototype.matchAll",
100
- "String.prototype.at",
101
- "StringReplaceAll",
102
- "StringMatchAll",
103
- "StringAt",
104
- "Object.assign",
105
- "Object.keys",
106
- "Object.values",
107
- "Object.entries",
108
- "Object.fromEntries",
109
- "Object.hasOwn",
25
+ "ErrorCause",
26
+ "ErrorIsError",
27
+ "Map",
28
+ "MapGroupBy",
29
+ "ObjectEntries",
30
+ "ObjectFromEntries",
31
+ "ObjectGroupBy",
110
32
  "ObjectHasOwn",
111
- "Promise.resolve",
112
- "Promise.reject",
113
- "Promise.all",
114
- "Promise.race",
115
- "Promise.allSettled",
116
- "Promise.any",
117
- "PromiseAny",
33
+ "ObjectValues",
34
+ "Promise",
118
35
  "PromiseAllSettled",
119
- "Map",
36
+ "PromiseAny",
37
+ "PromiseFinally",
38
+ "PromiseReject",
39
+ "PromiseResolve",
40
+ "PromiseTry",
41
+ "PromiseWithResolvers",
42
+ "RegExpEscape",
120
43
  "Set",
44
+ "SetDifference",
45
+ "SetIntersection",
46
+ "SetIsDisjointFrom",
47
+ "SetIsSubsetOf",
48
+ "SetIsSupersetOf",
49
+ "SetSymmetricDifference",
50
+ "SetUnion",
51
+ "StringIsWellFormed",
52
+ "StringMatchAll",
53
+ "StringPadEnd",
54
+ "StringPadStart",
55
+ "StringReplaceAll",
56
+ "StringToWellFormed",
57
+ "Symbol",
121
58
  "WeakMap",
122
59
  "WeakSet",
123
- "Symbol",
124
- "Symbol.iterator",
125
- "Symbol.asyncIterator",
126
60
  "globalThis",
127
- "GlobalThis",
128
61
  ]);
129
62
 
63
+ const POLYFILLABLE_FEATURES = coreJsPolyfillable;
64
+ const CORE_JS_POLYFILLABLE = coreJsPolyfillable;
65
+
130
66
  module.exports = {
131
67
  POLYFILLABLE_FEATURES,
132
68
  CORE_JS_POLYFILLABLE,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "es-check",
3
- "version": "9.6.0",
3
+ "version": "9.6.1",
4
4
  "description": "Checks the ECMAScript version of .js glob against a specified version of ECMAScript with a shell command",
5
5
  "main": "lib/index.js",
6
6
  "license": "MIT",
@@ -24,10 +24,13 @@
24
24
  "format:check": "prettier --check .",
25
25
  "pastoralist": "pastoralist",
26
26
  "pre-commit": "pnpm lint && pnpm format && pnpm test",
27
- "prepare": "node scripts/install-hooks.mjs",
27
+ "prepare": "node scripts/install/hooks.mjs",
28
28
  "prepublishOnly": "pnpm test",
29
29
  "release": "release-it --no-git.requireUpstream",
30
30
  "report:coverage": "mkdir -p coverage && node tests/scripts/test-runner.js unit --coverage --reporter=lcov",
31
+ "scripts:generate": "pnpm run scripts:generate:requirements && pnpm run scripts:generate:polyfills",
32
+ "scripts:generate:requirements": "node scripts/generate/requirements/parser.mjs",
33
+ "scripts:generate:polyfills": "node scripts/generate/polyfills/core.mjs",
31
34
  "test": "node tests/scripts/test-runner.js unit && npm run test:e2e",
32
35
  "test:unit": "node tests/scripts/test-runner.js unit",
33
36
  "test:unit:verbose": "node tests/scripts/test-runner.js unit --verbose",
@@ -37,8 +40,7 @@
37
40
  "test:e2e:esm": "node tests/e2e/test-esm-import.mjs",
38
41
  "test:e2e:package-files": "node tests/e2e/test-package-files.mjs",
39
42
  "test:e2e:sourcemap": "node --test tests/e2e/test-sourcemap.js --test-timeout=10000",
40
- "generate-parser-requirements": "node scripts/generate-parser-requirements.js",
41
- "update": "codependence --update && pastoralist && pnpm run generate-parser-requirements",
43
+ "update": "codependence --update && pastoralist && pnpm run scripts:generate",
42
44
  "benchmark": "./tests/benchmarks/run-benchmarks.sh",
43
45
  "site:dev": "pnpm --filter es-check-docs run dev",
44
46
  "site:build": "pnpm --filter es-check-docs run build",
@@ -59,6 +61,7 @@
59
61
  "@mdn/browser-compat-data": "^7.3.3",
60
62
  "browserslist": "^4.28.1",
61
63
  "codependence": "0.3.1",
64
+ "core-js-compat": "^3.48.0",
62
65
  "oxlint": "^1.49.0",
63
66
  "pastoralist": "1.10.0-1",
64
67
  "prettier": "3.8.1",
@@ -208,6 +211,21 @@
208
211
  "severity": "low",
209
212
  "url": "https://github.com/yowainwright/es-check/security/dependabot/61"
210
213
  }
214
+ },
215
+ "ajv@8.18.0": {
216
+ "dependents": {
217
+ "es-check": "ajv (transitive dependency)"
218
+ },
219
+ "ledger": {
220
+ "addedDate": "2026-02-21T09:31:35.017Z",
221
+ "reason": "Security fix: ajv has ReDoS when using `$data` option (medium)",
222
+ "securityChecked": true,
223
+ "securityCheckDate": "2026-02-21T09:31:35.017Z",
224
+ "securityProvider": "github",
225
+ "cve": "CVE-2025-69873",
226
+ "severity": "medium",
227
+ "url": "https://github.com/yowainwright/es-check/security/dependabot/67"
228
+ }
211
229
  }
212
230
  },
213
231
  "depPaths": [
@@ -231,7 +249,8 @@
231
249
  "undici": "6.23.0",
232
250
  "devalue": "5.6.3",
233
251
  "lodash": "4.17.23",
234
- "diff": "5.2.2"
252
+ "diff": "5.2.2",
253
+ "ajv": "8.18.0"
235
254
  },
236
255
  "workspaces": [
237
256
  "site"