@jsenv/core 38.3.11 → 38.4.0
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.
- package/README.md +17 -18
- package/dist/babel_helpers/AsyncGenerator/AsyncGenerator.js +3 -3
- package/dist/babel_helpers/AwaitValue/AwaitValue.js +2 -2
- package/dist/babel_helpers/{overloadYield/overloadYield.js → OverloadYield/OverloadYield.js} +1 -1
- package/dist/babel_helpers/applyDecoratedDescriptor/applyDecoratedDescriptor.js +23 -14
- package/dist/babel_helpers/applyDecs/applyDecs.js +32 -21
- package/dist/babel_helpers/applyDecs2203/applyDecs2203.js +549 -549
- package/dist/babel_helpers/applyDecs2203R/applyDecs2203R.js +27 -15
- package/dist/babel_helpers/applyDecs2301/applyDecs2301.js +29 -18
- package/dist/babel_helpers/applyDecs2305/applyDecs2305.js +362 -541
- package/dist/babel_helpers/arrayLikeToArray/arrayLikeToArray.js +4 -4
- package/dist/babel_helpers/arrayWithHoles/arrayWithHoles.js +2 -2
- package/dist/babel_helpers/arrayWithoutHoles/arrayWithoutHoles.js +3 -3
- package/dist/babel_helpers/assertThisInitialized/assertThisInitialized.js +5 -3
- package/dist/babel_helpers/asyncGeneratorDelegate/asyncGeneratorDelegate.js +2 -2
- package/dist/babel_helpers/asyncIterator/asyncIterator.js +1 -1
- package/dist/babel_helpers/asyncToGenerator/asyncToGenerator.js +17 -17
- package/dist/babel_helpers/awaitAsyncGenerator/awaitAsyncGenerator.js +2 -2
- package/dist/babel_helpers/callSuper/callSuper.js +25 -0
- package/dist/babel_helpers/checkInRHS/checkInRHS.js +10 -8
- package/dist/babel_helpers/classApplyDescriptorDestructureSet/classApplyDescriptorDestructureSet.js +9 -6
- package/dist/babel_helpers/classApplyDescriptorGet/classApplyDescriptorGet.js +2 -2
- package/dist/babel_helpers/classApplyDescriptorSet/classApplyDescriptorSet.js +3 -3
- package/dist/babel_helpers/classCallCheck/classCallCheck.js +1 -1
- package/dist/babel_helpers/classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js +5 -2
- package/dist/babel_helpers/classCheckPrivateStaticFieldDescriptor/classCheckPrivateStaticFieldDescriptor.js +7 -2
- package/dist/babel_helpers/classExtractFieldDescriptor/classExtractFieldDescriptor.js +9 -3
- package/dist/babel_helpers/classNameTDZError/classNameTDZError.js +3 -1
- package/dist/babel_helpers/classPrivateFieldDestructureSet/classPrivateFieldDestructureSet.js +4 -4
- package/dist/babel_helpers/classPrivateFieldGet/classPrivateFieldGet.js +4 -4
- package/dist/babel_helpers/classPrivateFieldLooseBase/classPrivateFieldLooseBase.js +2 -2
- package/dist/babel_helpers/classPrivateFieldLooseKey/classPrivateFieldLooseKey.js +2 -2
- package/dist/babel_helpers/classPrivateFieldSet/classPrivateFieldSet.js +5 -5
- package/dist/babel_helpers/classPrivateMethodGet/classPrivateMethodGet.js +2 -2
- package/dist/babel_helpers/classPrivateMethodSet/classPrivateMethodSet.js +1 -1
- package/dist/babel_helpers/classStaticPrivateFieldSpecGet/classStaticPrivateFieldSpecGet.js +11 -7
- package/dist/babel_helpers/classStaticPrivateFieldSpecSet/classStaticPrivateFieldSpecSet.js +7 -7
- package/dist/babel_helpers/classStaticPrivateMethodGet/classStaticPrivateMethodGet.js +8 -4
- package/dist/babel_helpers/classStaticPrivateMethodSet/classStaticPrivateMethodSet.js +1 -1
- package/dist/babel_helpers/construct/construct.js +18 -14
- package/dist/babel_helpers/createClass/createClass.js +1 -1
- package/dist/babel_helpers/createForOfIteratorHelper/createForOfIteratorHelper.js +21 -20
- package/dist/babel_helpers/createForOfIteratorHelperLoose/createForOfIteratorHelperLoose.js +10 -9
- package/dist/babel_helpers/createRawReactElement/createRawReactElement.js +11 -11
- package/dist/babel_helpers/createSuper/createSuper.js +11 -11
- package/dist/babel_helpers/decorate/decorate.js +255 -170
- package/dist/babel_helpers/defaults/defaults.js +5 -5
- package/dist/babel_helpers/defineAccessor/defineAccessor.js +1 -1
- package/dist/babel_helpers/defineEnumerableProperties/defineEnumerableProperties.js +11 -11
- package/dist/babel_helpers/defineProperty/defineProperty.js +4 -4
- package/dist/babel_helpers/dispose/dispose.js +39 -39
- package/dist/babel_helpers/extends/extends.js +4 -4
- package/dist/babel_helpers/get/get.js +2 -2
- package/dist/babel_helpers/getPrototypeOf/getPrototypeOf.js +1 -1
- package/dist/babel_helpers/identity/identity.js +1 -1
- package/dist/babel_helpers/importDeferProxy/importDeferProxy.js +27 -27
- package/dist/babel_helpers/inherits/inherits.js +4 -4
- package/dist/babel_helpers/inheritsLoose/inheritsLoose.js +4 -4
- package/dist/babel_helpers/initializerDefineProperty/initializerDefineProperty.js +5 -3
- package/dist/babel_helpers/initializerWarningHelper/initializerWarningHelper.js +1 -1
- package/dist/babel_helpers/instanceof/instanceof.js +7 -3
- package/dist/babel_helpers/interopRequireDefault/interopRequireDefault.js +1 -1
- package/dist/babel_helpers/interopRequireWildcard/interopRequireWildcard.js +3 -1
- package/dist/babel_helpers/isNativeFunction/isNativeFunction.js +1 -1
- package/dist/babel_helpers/isNativeReflectConstruct/isNativeReflectConstruct.js +12 -14
- package/dist/babel_helpers/iterableToArray/iterableToArray.js +1 -1
- package/dist/babel_helpers/iterableToArrayLimit/iterableToArrayLimit.js +1 -1
- package/dist/babel_helpers/iterableToArrayLimitLoose/iterableToArrayLimitLoose.js +1 -1
- package/dist/babel_helpers/jsx/jsx.js +1 -1
- package/dist/babel_helpers/maybeArrayLike/maybeArrayLike.js +4 -4
- package/dist/babel_helpers/newArrowCheck/newArrowCheck.js +1 -1
- package/dist/babel_helpers/nonIterableRest/nonIterableRest.js +2 -2
- package/dist/babel_helpers/nonIterableSpread/nonIterableSpread.js +2 -2
- package/dist/babel_helpers/nullishReceiverError/nullishReceiverError.js +1 -1
- package/dist/babel_helpers/objectDestructuringEmpty/objectDestructuringEmpty.js +1 -1
- package/dist/babel_helpers/objectSpread/objectSpread.js +8 -8
- package/dist/babel_helpers/objectSpread2/objectSpread2.js +5 -3
- package/dist/babel_helpers/objectWithoutProperties/objectWithoutProperties.js +12 -12
- package/dist/babel_helpers/objectWithoutPropertiesLoose/objectWithoutPropertiesLoose.js +10 -10
- package/dist/babel_helpers/possibleConstructorReturn/possibleConstructorReturn.js +7 -5
- package/dist/babel_helpers/readOnlyError/readOnlyError.js +1 -1
- package/dist/babel_helpers/regeneratorRuntime/regeneratorRuntime.js +1 -1
- package/dist/babel_helpers/set/set.js +22 -19
- package/dist/babel_helpers/setFunctionName/setFunctionName.js +18 -0
- package/dist/babel_helpers/setPrototypeOf/setPrototypeOf.js +7 -6
- package/dist/babel_helpers/skipFirstGeneratorNext/skipFirstGeneratorNext.js +4 -4
- package/dist/babel_helpers/slicedToArray/slicedToArray.js +5 -5
- package/dist/babel_helpers/slicedToArrayLoose/slicedToArrayLoose.js +5 -5
- package/dist/babel_helpers/superPropBase/superPropBase.js +4 -4
- package/dist/babel_helpers/taggedTemplateLiteral/taggedTemplateLiteral.js +2 -2
- package/dist/babel_helpers/taggedTemplateLiteralLoose/taggedTemplateLiteralLoose.js +3 -3
- package/dist/babel_helpers/tdz/tdz.js +1 -1
- package/dist/babel_helpers/temporalRef/temporalRef.js +3 -3
- package/dist/babel_helpers/toArray/toArray.js +5 -5
- package/dist/babel_helpers/toConsumableArray/toConsumableArray.js +5 -5
- package/dist/babel_helpers/toPrimitive/toPrimitive.js +11 -7
- package/dist/babel_helpers/toPropertyKey/toPropertyKey.js +8 -4
- package/dist/babel_helpers/typeof/typeof.js +6 -5
- package/dist/babel_helpers/unsupportedIterableToArray/unsupportedIterableToArray.js +7 -7
- package/dist/babel_helpers/using/using.js +20 -20
- package/dist/babel_helpers/wrapAsyncGenerator/wrapAsyncGenerator.js +3 -3
- package/dist/babel_helpers/wrapNativeSuper/wrapNativeSuper.js +12 -12
- package/dist/babel_helpers/wrapRegExp/wrapRegExp.js +5 -3
- package/dist/babel_helpers/writeOnlyError/writeOnlyError.js +1 -1
- package/dist/js/ribbon.js +1 -1
- package/dist/js/ws.js +234 -146
- package/dist/jsenv_core.js +1365 -1211
- package/package.json +26 -22
- package/src/build/build.js +22 -14
- package/src/dev/start_dev_server.js +8 -21
- package/src/kitchen/errors.js +29 -24
- package/src/kitchen/kitchen.js +1 -1
- package/src/kitchen/url_graph/references.js +8 -0
- package/src/kitchen/url_graph/url_graph_report.js +5 -3
- package/src/plugins/plugins.js +2 -2
- package/src/plugins/protocol_file/jsenv_plugin_protocol_file.js +17 -7
- package/src/plugins/reference_analysis/js/jsenv_plugin_js_reference_analysis.js +10 -12
- package/src/plugins/ribbon/client/ribbon.js +1 -1
|
@@ -1,44 +1,47 @@
|
|
|
1
|
-
import superPropBase from "../superPropBase/superPropBase.js"
|
|
2
|
-
import defineProperty from "../defineProperty/defineProperty.js"
|
|
1
|
+
import superPropBase from "../superPropBase/superPropBase.js";
|
|
2
|
+
import defineProperty from "../defineProperty/defineProperty.js";
|
|
3
3
|
|
|
4
4
|
function reflectSetPolyfill(target, property, value, receiver) {
|
|
5
|
-
var base = superPropBase(target, property)
|
|
6
|
-
var desc
|
|
5
|
+
var base = superPropBase(target, property);
|
|
6
|
+
var desc;
|
|
7
7
|
if (base) {
|
|
8
|
-
desc = Object.getOwnPropertyDescriptor(base, property)
|
|
8
|
+
desc = Object.getOwnPropertyDescriptor(base, property);
|
|
9
9
|
if (desc.set) {
|
|
10
|
-
desc.set.call(receiver, value)
|
|
11
|
-
return true
|
|
10
|
+
desc.set.call(receiver, value);
|
|
11
|
+
return true;
|
|
12
12
|
} else if (!desc.writable) {
|
|
13
13
|
// Both getter and non-writable fall into this.
|
|
14
|
-
return false
|
|
14
|
+
return false;
|
|
15
15
|
}
|
|
16
16
|
}
|
|
17
17
|
// Without a super that defines the property, spec boils down to
|
|
18
18
|
// "define on receiver" for some reason.
|
|
19
|
-
desc = Object.getOwnPropertyDescriptor(receiver, property)
|
|
19
|
+
desc = Object.getOwnPropertyDescriptor(receiver, property);
|
|
20
20
|
if (desc) {
|
|
21
21
|
if (!desc.writable) {
|
|
22
22
|
// Setter, getter, and non-writable fall into this.
|
|
23
|
-
return false
|
|
23
|
+
return false;
|
|
24
24
|
}
|
|
25
|
-
desc.value = value
|
|
26
|
-
Object.defineProperty(receiver, property, desc)
|
|
25
|
+
desc.value = value;
|
|
26
|
+
Object.defineProperty(receiver, property, desc);
|
|
27
27
|
} else {
|
|
28
28
|
// Avoid setters that may be defined on Sub's prototype, but not on
|
|
29
29
|
// the instance.
|
|
30
|
-
defineProperty(receiver, property, value)
|
|
30
|
+
defineProperty(receiver, property, value);
|
|
31
31
|
}
|
|
32
|
-
return true
|
|
32
|
+
return true;
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
var reflectSet =
|
|
35
|
+
var reflectSet =
|
|
36
|
+
typeof Reflect !== "undefined" && Reflect.set
|
|
37
|
+
? Reflect.set
|
|
38
|
+
: reflectSetPolyfill;
|
|
36
39
|
|
|
37
40
|
export default (target, property, value, receiver, isStrict) => {
|
|
38
41
|
// eslint-disable-next-line no-obj-calls
|
|
39
|
-
var s = reflectSet(target, property, value, receiver || target)
|
|
42
|
+
var s = reflectSet(target, property, value, receiver || target);
|
|
40
43
|
if (!s && isStrict) {
|
|
41
|
-
throw new TypeError("failed to set property")
|
|
44
|
+
throw new TypeError("failed to set property");
|
|
42
45
|
}
|
|
43
|
-
return value
|
|
44
|
-
}
|
|
46
|
+
return value;
|
|
47
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/* @minVersion 7.23.6 */
|
|
2
|
+
|
|
3
|
+
// https://tc39.es/ecma262/#sec-setfunctionname
|
|
4
|
+
export default function setFunctionName(fn, name, prefix) {
|
|
5
|
+
if (typeof name === "symbol") {
|
|
6
|
+
name = name.description;
|
|
7
|
+
name = name ? "[" + name + "]" : "";
|
|
8
|
+
}
|
|
9
|
+
// In some older browsers .name was non-configurable, here we catch any
|
|
10
|
+
// errors thrown by defineProperty.
|
|
11
|
+
try {
|
|
12
|
+
Object.defineProperty(fn, "name", {
|
|
13
|
+
configurable: true,
|
|
14
|
+
value: prefix ? prefix + " " + name : name,
|
|
15
|
+
});
|
|
16
|
+
} catch (_) {}
|
|
17
|
+
return fn;
|
|
18
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
export default Object.setPrototypeOf
|
|
2
|
-
(
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
export default Object.setPrototypeOf
|
|
2
|
+
? Object.setPrototypeOf.bind()
|
|
3
|
+
: (o, p) => {
|
|
4
|
+
// eslint-disable-next-line no-proto
|
|
5
|
+
o.__proto__ = p;
|
|
6
|
+
return o;
|
|
7
|
+
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import arrayWithHoles from "../arrayWithHoles/arrayWithHoles.js"
|
|
2
|
-
import iterableToArrayLimit from "../iterableToArrayLimit/iterableToArrayLimit.js"
|
|
3
|
-
import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js"
|
|
4
|
-
import nonIterableRest from "../nonIterableRest/nonIterableRest.js"
|
|
1
|
+
import arrayWithHoles from "../arrayWithHoles/arrayWithHoles.js";
|
|
2
|
+
import iterableToArrayLimit from "../iterableToArrayLimit/iterableToArrayLimit.js";
|
|
3
|
+
import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js";
|
|
4
|
+
import nonIterableRest from "../nonIterableRest/nonIterableRest.js";
|
|
5
5
|
|
|
6
6
|
export default (arr, i) =>
|
|
7
7
|
arrayWithHoles(arr) ||
|
|
8
8
|
iterableToArrayLimit(arr, i) ||
|
|
9
9
|
unsupportedIterableToArray(arr, i) ||
|
|
10
|
-
nonIterableRest()
|
|
10
|
+
nonIterableRest();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import arrayWithHoles from "../arrayWithHoles/arrayWithHoles.js"
|
|
2
|
-
import iterableToArrayLimitLoose from "../iterableToArrayLimitLoose/iterableToArrayLimitLoose.js"
|
|
3
|
-
import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js"
|
|
4
|
-
import nonIterableRest from "../nonIterableRest/nonIterableRest.js"
|
|
1
|
+
import arrayWithHoles from "../arrayWithHoles/arrayWithHoles.js";
|
|
2
|
+
import iterableToArrayLimitLoose from "../iterableToArrayLimitLoose/iterableToArrayLimitLoose.js";
|
|
3
|
+
import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js";
|
|
4
|
+
import nonIterableRest from "../nonIterableRest/nonIterableRest.js";
|
|
5
5
|
|
|
6
6
|
export default function (arr, i) {
|
|
7
7
|
return (
|
|
@@ -9,5 +9,5 @@ export default function (arr, i) {
|
|
|
9
9
|
iterableToArrayLimitLoose(arr, i) ||
|
|
10
10
|
unsupportedIterableToArray(arr, i) ||
|
|
11
11
|
nonIterableRest()
|
|
12
|
-
)
|
|
12
|
+
);
|
|
13
13
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import getPrototypeOf from "../getPrototypeOf/getPrototypeOf.js"
|
|
1
|
+
import getPrototypeOf from "../getPrototypeOf/getPrototypeOf.js";
|
|
2
2
|
|
|
3
3
|
export default function (object, property) {
|
|
4
4
|
// Yes, this throws if object is null to being with, that's on purpose.
|
|
5
5
|
while (!Object.prototype.hasOwnProperty.call(object, property)) {
|
|
6
|
-
object = getPrototypeOf(object)
|
|
7
|
-
if (object === null) break
|
|
6
|
+
object = getPrototypeOf(object);
|
|
7
|
+
if (object === null) break;
|
|
8
8
|
}
|
|
9
|
-
return object
|
|
9
|
+
return object;
|
|
10
10
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import undef from "../temporalUndefined/temporalUndefined.js"
|
|
2
|
-
import err from "../tdz/tdz.js"
|
|
1
|
+
import undef from "../temporalUndefined/temporalUndefined.js";
|
|
2
|
+
import err from "../tdz/tdz.js";
|
|
3
3
|
|
|
4
4
|
export default function (val, name) {
|
|
5
|
-
return val === undef ? err(name) : val
|
|
5
|
+
return val === undef ? err(name) : val;
|
|
6
6
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import arrayWithHoles from "../arrayWithHoles/arrayWithHoles.js"
|
|
2
|
-
import iterableToArray from "../iterableToArray/iterableToArray.js"
|
|
3
|
-
import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js"
|
|
4
|
-
import nonIterableRest from "../nonIterableRest/nonIterableRest.js"
|
|
1
|
+
import arrayWithHoles from "../arrayWithHoles/arrayWithHoles.js";
|
|
2
|
+
import iterableToArray from "../iterableToArray/iterableToArray.js";
|
|
3
|
+
import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js";
|
|
4
|
+
import nonIterableRest from "../nonIterableRest/nonIterableRest.js";
|
|
5
5
|
|
|
6
6
|
export default (arr) =>
|
|
7
7
|
arrayWithHoles(arr) ||
|
|
8
8
|
iterableToArray(arr) ||
|
|
9
9
|
unsupportedIterableToArray(arr) ||
|
|
10
|
-
nonIterableRest()
|
|
10
|
+
nonIterableRest();
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import arrayWithoutHoles from "../arrayWithoutHoles/arrayWithoutHoles.js"
|
|
2
|
-
import iterableToArray from "../iterableToArray/iterableToArray.js"
|
|
3
|
-
import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js"
|
|
4
|
-
import nonIterableSpread from "../nonIterableSpread/nonIterableSpread.js"
|
|
1
|
+
import arrayWithoutHoles from "../arrayWithoutHoles/arrayWithoutHoles.js";
|
|
2
|
+
import iterableToArray from "../iterableToArray/iterableToArray.js";
|
|
3
|
+
import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js";
|
|
4
|
+
import nonIterableSpread from "../nonIterableSpread/nonIterableSpread.js";
|
|
5
5
|
|
|
6
6
|
export default (arr) =>
|
|
7
7
|
arrayWithoutHoles(arr) ||
|
|
8
8
|
iterableToArray(arr) ||
|
|
9
9
|
unsupportedIterableToArray(arr) ||
|
|
10
|
-
nonIterableSpread()
|
|
10
|
+
nonIterableSpread();
|
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
/* @minVersion 7.1.5 */
|
|
2
|
+
|
|
3
|
+
// https://tc39.es/ecma262/#sec-toprimitive
|
|
4
|
+
export default function toPrimitive(input, hint) {
|
|
5
|
+
if (typeof input !== "object" || !input) return input;
|
|
6
|
+
// @ts-expect-error Symbol.toPrimitive might not index {}
|
|
7
|
+
var prim = input[Symbol.toPrimitive];
|
|
4
8
|
if (prim !== undefined) {
|
|
5
|
-
var res = prim.call(input, hint || "default")
|
|
6
|
-
if (typeof res !== "object") return res
|
|
7
|
-
throw new TypeError("@@toPrimitive must return a primitive value.")
|
|
9
|
+
var res = prim.call(input, hint || "default");
|
|
10
|
+
if (typeof res !== "object") return res;
|
|
11
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
8
12
|
}
|
|
9
|
-
return (hint === "string" ? String : Number)(input)
|
|
13
|
+
return (hint === "string" ? String : Number)(input);
|
|
10
14
|
}
|
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
/* @minVersion 7.1.5 */
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
// https://tc39.es/ecma262/#sec-topropertykey
|
|
4
|
+
|
|
5
|
+
import toPrimitive from "../toPrimitive/toPrimitive.js";
|
|
6
|
+
|
|
7
|
+
export default function toPropertyKey(arg) {
|
|
8
|
+
var key = toPrimitive(arg, "string");
|
|
9
|
+
return typeof key === "symbol" ? key : String(key);
|
|
6
10
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const nativeTypeOf = (obj) => typeof obj
|
|
1
|
+
const nativeTypeOf = (obj) => typeof obj;
|
|
2
2
|
|
|
3
3
|
const customTypeOf = (obj) => {
|
|
4
4
|
return obj &&
|
|
@@ -6,9 +6,10 @@ const customTypeOf = (obj) => {
|
|
|
6
6
|
obj.constructor === Symbol &&
|
|
7
7
|
obj !== Symbol.prototype
|
|
8
8
|
? "symbol"
|
|
9
|
-
: typeof obj
|
|
10
|
-
}
|
|
9
|
+
: typeof obj;
|
|
10
|
+
};
|
|
11
11
|
|
|
12
|
-
export default typeof Symbol === "function" &&
|
|
12
|
+
export default typeof Symbol === "function" &&
|
|
13
|
+
typeof Symbol.iterator === "symbol"
|
|
13
14
|
? nativeTypeOf
|
|
14
|
-
: customTypeOf
|
|
15
|
+
: customTypeOf;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/* eslint-disable consistent-return */
|
|
2
|
-
import arrayLikeToArray from "../arrayLikeToArray/arrayLikeToArray.js"
|
|
2
|
+
import arrayLikeToArray from "../arrayLikeToArray/arrayLikeToArray.js";
|
|
3
3
|
|
|
4
4
|
export default function unsupportedIterableToArray(o, minLen) {
|
|
5
|
-
if (!o) return
|
|
6
|
-
if (typeof o === "string") return arrayLikeToArray(o, minLen)
|
|
7
|
-
var n = Object.prototype.toString.call(o).slice(8, -1)
|
|
8
|
-
if (n === "Object" && o.constructor) n = o.constructor.name
|
|
9
|
-
if (n === "Map" || n === "Set") return Array.from(o)
|
|
5
|
+
if (!o) return;
|
|
6
|
+
if (typeof o === "string") return arrayLikeToArray(o, minLen);
|
|
7
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
8
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
9
|
+
if (n === "Map" || n === "Set") return Array.from(o);
|
|
10
10
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
11
|
-
return arrayLikeToArray(o, minLen)
|
|
11
|
+
return arrayLikeToArray(o, minLen);
|
|
12
12
|
}
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
/* @minVersion 7.22.0 */
|
|
2
2
|
|
|
3
3
|
export default function _using(stack, value, isAwait) {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
4
|
+
if (value === null || value === void 0) return value;
|
|
5
|
+
if (Object(value) !== value) {
|
|
6
|
+
throw new TypeError(
|
|
7
|
+
"using declarations can only be used with objects, functions, null, or undefined.",
|
|
8
|
+
);
|
|
9
|
+
}
|
|
10
|
+
// core-js-pure uses Symbol.for for polyfilling well-known symbols
|
|
11
|
+
if (isAwait) {
|
|
12
|
+
var dispose =
|
|
13
|
+
value[Symbol.asyncDispose || Symbol.for("Symbol.asyncDispose")];
|
|
14
|
+
}
|
|
15
|
+
if (dispose === null || dispose === void 0) {
|
|
16
|
+
dispose = value[Symbol.dispose || Symbol.for("Symbol.dispose")];
|
|
17
|
+
}
|
|
18
|
+
if (typeof dispose !== "function") {
|
|
19
|
+
throw new TypeError(`Property [Symbol.dispose] is not a function.`);
|
|
20
|
+
}
|
|
21
|
+
stack.push({ v: value, d: dispose, a: isAwait });
|
|
22
|
+
return value;
|
|
23
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import AsyncGenerator from "../AsyncGenerator/AsyncGenerator.js"
|
|
1
|
+
import AsyncGenerator from "../AsyncGenerator/AsyncGenerator.js";
|
|
2
2
|
|
|
3
3
|
export default function (fn) {
|
|
4
4
|
return function () {
|
|
5
5
|
// eslint-disable-next-line prefer-rest-params
|
|
6
|
-
return new AsyncGenerator(fn.apply(this, arguments))
|
|
7
|
-
}
|
|
6
|
+
return new AsyncGenerator(fn.apply(this, arguments));
|
|
7
|
+
};
|
|
8
8
|
}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import getPrototypeOf from "../getPrototypeOf/getPrototypeOf.js"
|
|
2
|
-
import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js"
|
|
3
|
-
import isNativeFunction from "../isNativeFunction/isNativeFunction.js"
|
|
4
|
-
import construct from "../construct/construct.js"
|
|
1
|
+
import getPrototypeOf from "../getPrototypeOf/getPrototypeOf.js";
|
|
2
|
+
import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js";
|
|
3
|
+
import isNativeFunction from "../isNativeFunction/isNativeFunction.js";
|
|
4
|
+
import construct from "../construct/construct.js";
|
|
5
5
|
|
|
6
|
-
var _cache = typeof Map === "function" ? new Map() : undefined
|
|
6
|
+
var _cache = typeof Map === "function" ? new Map() : undefined;
|
|
7
7
|
|
|
8
8
|
export default function (Class) {
|
|
9
|
-
if (Class === null || !isNativeFunction(Class)) return Class
|
|
9
|
+
if (Class === null || !isNativeFunction(Class)) return Class;
|
|
10
10
|
if (typeof Class !== "function") {
|
|
11
|
-
throw new TypeError("Super expression must either be null or a function")
|
|
11
|
+
throw new TypeError("Super expression must either be null or a function");
|
|
12
12
|
}
|
|
13
13
|
if (typeof _cache !== "undefined") {
|
|
14
|
-
if (_cache.has(Class)) return _cache.get(Class)
|
|
15
|
-
_cache.set(Class, Wrapper)
|
|
14
|
+
if (_cache.has(Class)) return _cache.get(Class);
|
|
15
|
+
_cache.set(Class, Wrapper);
|
|
16
16
|
}
|
|
17
17
|
function Wrapper() {
|
|
18
18
|
// eslint-disable-next-line prefer-rest-params
|
|
19
|
-
return construct(Class, arguments, getPrototypeOf(this).constructor)
|
|
19
|
+
return construct(Class, arguments, getPrototypeOf(this).constructor);
|
|
20
20
|
}
|
|
21
21
|
Wrapper.prototype = Object.create(Class.prototype, {
|
|
22
22
|
constructor: {
|
|
@@ -25,6 +25,6 @@ export default function (Class) {
|
|
|
25
25
|
writable: true,
|
|
26
26
|
configurable: true,
|
|
27
27
|
},
|
|
28
|
-
})
|
|
29
|
-
return setPrototypeOf(Wrapper, Class)
|
|
28
|
+
});
|
|
29
|
+
return setPrototypeOf(Wrapper, Class);
|
|
30
30
|
}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
/* @minVersion 7.19.0 */
|
|
2
|
+
|
|
3
|
+
import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js";
|
|
4
|
+
import inherits from "../inherits/inherits.js";
|
|
3
5
|
|
|
4
6
|
export default function _wrapRegExp() {
|
|
5
7
|
_wrapRegExp = function (re, groups) {
|
|
@@ -35,7 +37,7 @@ export default function _wrapRegExp() {
|
|
|
35
37
|
substitution.replace(/\$<([^>]+)>/g, function (_, name) {
|
|
36
38
|
var group = groups[name];
|
|
37
39
|
return "$" + (Array.isArray(group) ? group.join("$") : group);
|
|
38
|
-
})
|
|
40
|
+
}),
|
|
39
41
|
);
|
|
40
42
|
} else if (typeof substitution === "function") {
|
|
41
43
|
var _this = this;
|