Skip to content

Commit

Permalink
add instance methods polyfills to collections static methods that pro…
Browse files Browse the repository at this point in the history
…duce collection instances
  • Loading branch information
zloirock committed Feb 3, 2024
1 parent f1af7fc commit b2dba12
Show file tree
Hide file tree
Showing 12 changed files with 107 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
- Fixed a missed check in `Array#{ indexOf, lastIndexOf, includes }`, [#1325](https://github.com/zloirock/core-js/issues/1325), thanks [**@minseok-choe**](https://github.com/minseok-choe)
- Fixed `Array.from` and some other methods with proxy targets, [#1322](https://github.com/zloirock/core-js/issues/1322), thanks [**@minseok-choe**](https://github.com/minseok-choe)
- Dropped context workaround from collection static methods entries since with current methods semantic it's no longer required
- Added instance methods polyfills to entries of collections static methods that produce collection instances
- Added missed `Date#toJSON` to `JSON.stringify` entries dependencies
- Compat data improvements:
- [New `Set` methods](https://github.com/tc39/proposal-set-methods) [fixed](https://bugs.chromium.org/p/v8/issues/detail?id=14559#c4) and marked as supported from V8 ~ Chrome 123
Expand Down
1 change: 1 addition & 0 deletions packages/core-js/es/map/group-by.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.map');
require('../../modules/es.map.group-by');
var path = require('../../internals/path');
Expand Down
15 changes: 15 additions & 0 deletions packages/core-js/full/map/from.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,23 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.array.iterator');
require('../../modules/es.map');
require('../../modules/es.string.iterator');
require('../../modules/esnext.map.from');
require('../../modules/esnext.map.delete-all');
require('../../modules/esnext.map.emplace');
require('../../modules/esnext.map.every');
require('../../modules/esnext.map.filter');
require('../../modules/esnext.map.find');
require('../../modules/esnext.map.find-key');
require('../../modules/esnext.map.includes');
require('../../modules/esnext.map.key-of');
require('../../modules/esnext.map.map-keys');
require('../../modules/esnext.map.map-values');
require('../../modules/esnext.map.merge');
require('../../modules/esnext.map.reduce');
require('../../modules/esnext.map.some');
require('../../modules/esnext.map.update');
require('../../modules/web.dom-collections.iterator');
var path = require('../../internals/path');

Expand Down
14 changes: 14 additions & 0 deletions packages/core-js/full/map/group-by.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,18 @@
'use strict';
var parent = require('../../actual/map/group-by');
require('../../modules/esnext.map.delete-all');
require('../../modules/esnext.map.emplace');
require('../../modules/esnext.map.every');
require('../../modules/esnext.map.filter');
require('../../modules/esnext.map.find');
require('../../modules/esnext.map.find-key');
require('../../modules/esnext.map.includes');
require('../../modules/esnext.map.key-of');
require('../../modules/esnext.map.map-keys');
require('../../modules/esnext.map.map-values');
require('../../modules/esnext.map.merge');
require('../../modules/esnext.map.reduce');
require('../../modules/esnext.map.some');
require('../../modules/esnext.map.update');

module.exports = parent;
15 changes: 15 additions & 0 deletions packages/core-js/full/map/key-by.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,21 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.map');
require('../../modules/esnext.map.key-by');
require('../../modules/esnext.map.delete-all');
require('../../modules/esnext.map.emplace');
require('../../modules/esnext.map.every');
require('../../modules/esnext.map.filter');
require('../../modules/esnext.map.find');
require('../../modules/esnext.map.find-key');
require('../../modules/esnext.map.includes');
require('../../modules/esnext.map.key-of');
require('../../modules/esnext.map.map-keys');
require('../../modules/esnext.map.map-values');
require('../../modules/esnext.map.merge');
require('../../modules/esnext.map.reduce');
require('../../modules/esnext.map.some');
require('../../modules/esnext.map.update');
var call = require('../../internals/function-call');
var isCallable = require('../../internals/is-callable');
var path = require('../../internals/path');
Expand Down
15 changes: 15 additions & 0 deletions packages/core-js/full/map/of.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,22 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.array.iterator');
require('../../modules/es.map');
require('../../modules/esnext.map.of');
require('../../modules/esnext.map.delete-all');
require('../../modules/esnext.map.emplace');
require('../../modules/esnext.map.every');
require('../../modules/esnext.map.filter');
require('../../modules/esnext.map.find');
require('../../modules/esnext.map.find-key');
require('../../modules/esnext.map.includes');
require('../../modules/esnext.map.key-of');
require('../../modules/esnext.map.map-keys');
require('../../modules/esnext.map.map-values');
require('../../modules/esnext.map.merge');
require('../../modules/esnext.map.reduce');
require('../../modules/esnext.map.some');
require('../../modules/esnext.map.update');
var path = require('../../internals/path');

module.exports = path.Map.of;
17 changes: 17 additions & 0 deletions packages/core-js/full/set/from.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,25 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.array.iterator');
require('../../modules/es.set');
require('../../modules/es.string.iterator');
require('../../modules/esnext.set.from');
require('../../modules/esnext.set.add-all');
require('../../modules/esnext.set.delete-all');
require('../../modules/esnext.set.difference.v2');
require('../../modules/esnext.set.every');
require('../../modules/esnext.set.filter');
require('../../modules/esnext.set.find');
require('../../modules/esnext.set.join');
require('../../modules/esnext.set.intersection.v2');
require('../../modules/esnext.set.is-disjoint-from.v2');
require('../../modules/esnext.set.is-subset-of.v2');
require('../../modules/esnext.set.is-superset-of.v2');
require('../../modules/esnext.set.map');
require('../../modules/esnext.set.reduce');
require('../../modules/esnext.set.some');
require('../../modules/esnext.set.symmetric-difference.v2');
require('../../modules/esnext.set.union.v2');
require('../../modules/web.dom-collections.iterator');
var path = require('../../internals/path');

Expand Down
17 changes: 17 additions & 0 deletions packages/core-js/full/set/of.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,24 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.array.iterator');
require('../../modules/es.set');
require('../../modules/esnext.set.of');
require('../../modules/esnext.set.add-all');
require('../../modules/esnext.set.delete-all');
require('../../modules/esnext.set.difference.v2');
require('../../modules/esnext.set.every');
require('../../modules/esnext.set.filter');
require('../../modules/esnext.set.find');
require('../../modules/esnext.set.join');
require('../../modules/esnext.set.intersection.v2');
require('../../modules/esnext.set.is-disjoint-from.v2');
require('../../modules/esnext.set.is-subset-of.v2');
require('../../modules/esnext.set.is-superset-of.v2');
require('../../modules/esnext.set.map');
require('../../modules/esnext.set.reduce');
require('../../modules/esnext.set.some');
require('../../modules/esnext.set.symmetric-difference.v2');
require('../../modules/esnext.set.union.v2');
var path = require('../../internals/path');

module.exports = path.Set.of;
3 changes: 3 additions & 0 deletions packages/core-js/full/weak-map/from.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.array.iterator');
require('../../modules/es.string.iterator');
require('../../modules/es.weak-map');
require('../../modules/esnext.weak-map.from');
require('../../modules/esnext.weak-map.delete-all');
require('../../modules/esnext.weak-map.emplace');
require('../../modules/web.dom-collections.iterator');
var path = require('../../internals/path');

Expand Down
3 changes: 3 additions & 0 deletions packages/core-js/full/weak-map/of.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.array.iterator');
require('../../modules/es.weak-map');
require('../../modules/esnext.weak-map.of');
require('../../modules/esnext.weak-map.delete-all');
require('../../modules/esnext.weak-map.emplace');
var path = require('../../internals/path');

module.exports = path.WeakMap.of;
3 changes: 3 additions & 0 deletions packages/core-js/full/weak-set/from.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.array.iterator');
require('../../modules/es.string.iterator');
require('../../modules/es.weak-set');
require('../../modules/esnext.weak-set.from');
require('../../modules/esnext.weak-set.add-all');
require('../../modules/esnext.weak-set.delete-all');
require('../../modules/web.dom-collections.iterator');
var path = require('../../internals/path');

Expand Down
3 changes: 3 additions & 0 deletions packages/core-js/full/weak-set/of.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
'use strict';
require('../../modules/es.object.to-string');
require('../../modules/es.array.iterator');
require('../../modules/es.weak-set');
require('../../modules/esnext.weak-set.of');
require('../../modules/esnext.weak-set.add-all');
require('../../modules/esnext.weak-set.delete-all');
var path = require('../../internals/path');

module.exports = path.WeakSet.of;

0 comments on commit b2dba12

Please sign in to comment.