-
-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add missing things in core-js-pure 3 #198
Conversation
pure
pure
pure
@@ -355,7 +355,7 @@ export const StaticProperties: ObjectMap2<CoreJSPolyfillDescriptor> = { | |||
}, | |||
|
|||
ArrayBuffer: { | |||
isView: define(null, ["es.array-buffer.is-view"]), | |||
isView: define("array-buffer/is-view", ["es.array-buffer.is-view"]), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's missed in the pure version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
groupBy: define(null, ["es.map.group-by", ...MapDependencies]), | ||
keyBy: define(null, ["esnext.map.key-by", ...MapDependencies]), | ||
of: define(null, ["esnext.map.of", ...MapDependencies]), | ||
from: define("map/from", ["esnext.map.from", ...MapDependencies]), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.from
and .of
are present in all collections.
Yes, it looks like a partial workaround. |
"es.promise.any", | ||
"es.aggregate-error", | ||
...PromiseDependenciesWithIterators, | ||
]), | ||
race: define(null, PromiseDependenciesWithIterators), | ||
try: define(null, ["esnext.promise.try", ...PromiseDependencies]), | ||
try: define("promise/try", ["esnext.promise.try", ...PromiseDependencies]), | ||
withResolvers: define(null, [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's also a static method - it was added recently, but with Map.groupBy
situation the same.
_WeakMap.from; | ||
_ArrayBuffer$isView; | ||
Uint8Array.from; | ||
Uint8Array.of; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this expected? I didn't find the corresponding file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All typed array features are not polyfilled in the pure version.
f819cb0
to
6dd5400
Compare
...ges/babel-plugin-polyfill-corejs3/test/fixtures/usage-pure/built-in-static-methods/output.js
Outdated
Show resolved
Hide resolved
Thank you! |
That means that those entries should be defined for all collections, not removed from |
Oops, I just tested that |
Fixes: #166
It seems that issues is not the optimization logic, but that we don't define the data of
corejs-pure
.