@jsenv/core 36.2.1 → 36.3.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.
Files changed (124) hide show
  1. package/dist/babel_helpers/AsyncGenerator/AsyncGenerator.js +45 -35
  2. package/dist/babel_helpers/AwaitValue/AwaitValue.js +3 -3
  3. package/dist/babel_helpers/applyDecoratedDescriptor/applyDecoratedDescriptor.js +13 -13
  4. package/dist/babel_helpers/applyDecs/applyDecs.js +227 -42
  5. package/dist/babel_helpers/applyDecs2203/applyDecs2203.js +559 -418
  6. package/dist/babel_helpers/applyDecs2203R/applyDecs2203R.js +235 -87
  7. package/dist/babel_helpers/applyDecs2301/applyDecs2301.js +591 -456
  8. package/dist/babel_helpers/applyDecs2305/applyDecs2305.js +681 -0
  9. package/dist/babel_helpers/arrayLikeToArray/arrayLikeToArray.js +5 -5
  10. package/dist/babel_helpers/arrayWithHoles/arrayWithHoles.js +3 -3
  11. package/dist/babel_helpers/arrayWithoutHoles/arrayWithoutHoles.js +4 -4
  12. package/dist/babel_helpers/assertThisInitialized/assertThisInitialized.js +4 -4
  13. package/dist/babel_helpers/asyncGeneratorDelegate/asyncGeneratorDelegate.js +12 -4
  14. package/dist/babel_helpers/asyncIterator/asyncIterator.js +13 -11
  15. package/dist/babel_helpers/asyncToGenerator/asyncToGenerator.js +18 -17
  16. package/dist/babel_helpers/awaitAsyncGenerator/awaitAsyncGenerator.js +2 -1
  17. package/dist/babel_helpers/checkInRHS/checkInRHS.js +8 -5
  18. package/dist/babel_helpers/classApplyDescriptorDestructureSet/classApplyDescriptorDestructureSet.js +7 -7
  19. package/dist/babel_helpers/classApplyDescriptorGet/classApplyDescriptorGet.js +3 -3
  20. package/dist/babel_helpers/classApplyDescriptorSet/classApplyDescriptorSet.js +4 -4
  21. package/dist/babel_helpers/classCallCheck/classCallCheck.js +2 -2
  22. package/dist/babel_helpers/classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js +2 -2
  23. package/dist/babel_helpers/classCheckPrivateStaticFieldDescriptor/classCheckPrivateStaticFieldDescriptor.js +2 -2
  24. package/dist/babel_helpers/classExtractFieldDescriptor/classExtractFieldDescriptor.js +3 -3
  25. package/dist/babel_helpers/classNameTDZError/classNameTDZError.js +2 -2
  26. package/dist/babel_helpers/classPrivateFieldDestructureSet/classPrivateFieldDestructureSet.js +6 -5
  27. package/dist/babel_helpers/classPrivateFieldGet/classPrivateFieldGet.js +6 -5
  28. package/dist/babel_helpers/classPrivateFieldLooseBase/classPrivateFieldLooseBase.js +3 -3
  29. package/dist/babel_helpers/classPrivateFieldLooseKey/classPrivateFieldLooseKey.js +3 -3
  30. package/dist/babel_helpers/classPrivateFieldSet/classPrivateFieldSet.js +7 -6
  31. package/dist/babel_helpers/classPrivateMethodGet/classPrivateMethodGet.js +3 -3
  32. package/dist/babel_helpers/classPrivateMethodSet/classPrivateMethodSet.js +2 -2
  33. package/dist/babel_helpers/classStaticPrivateFieldSpecGet/classStaticPrivateFieldSpecGet.js +8 -7
  34. package/dist/babel_helpers/classStaticPrivateFieldSpecSet/classStaticPrivateFieldSpecSet.js +15 -9
  35. package/dist/babel_helpers/classStaticPrivateMethodGet/classStaticPrivateMethodGet.js +5 -4
  36. package/dist/babel_helpers/classStaticPrivateMethodSet/classStaticPrivateMethodSet.js +2 -2
  37. package/dist/babel_helpers/construct/construct.js +10 -9
  38. package/dist/babel_helpers/createClass/createClass.js +2 -3
  39. package/dist/babel_helpers/createForOfIteratorHelper/createForOfIteratorHelper.js +30 -29
  40. package/dist/babel_helpers/createForOfIteratorHelperLoose/createForOfIteratorHelperLoose.js +18 -16
  41. package/dist/babel_helpers/createRawReactElement/createRawReactElement.js +23 -17
  42. package/dist/babel_helpers/createSuper/createSuper.js +14 -12
  43. package/dist/babel_helpers/decorate/decorate.js +242 -210
  44. package/dist/babel_helpers/defaults/defaults.js +6 -6
  45. package/dist/babel_helpers/defineAccessor/defineAccessor.js +1 -4
  46. package/dist/babel_helpers/defineEnumerableProperties/defineEnumerableProperties.js +12 -12
  47. package/dist/babel_helpers/defineProperty/defineProperty.js +7 -6
  48. package/dist/babel_helpers/extends/extends.js +5 -4
  49. package/dist/babel_helpers/get/get.js +2 -1
  50. package/dist/babel_helpers/getPrototypeOf/getPrototypeOf.js +4 -3
  51. package/dist/babel_helpers/inherits/inherits.js +3 -4
  52. package/dist/babel_helpers/inheritsLoose/inheritsLoose.js +6 -5
  53. package/dist/babel_helpers/initializerDefineProperty/initializerDefineProperty.js +4 -4
  54. package/dist/babel_helpers/initializerWarningHelper/initializerWarningHelper.js +5 -2
  55. package/dist/babel_helpers/instanceof/instanceof.js +3 -3
  56. package/dist/babel_helpers/interopRequireDefault/interopRequireDefault.js +2 -4
  57. package/dist/babel_helpers/interopRequireWildcard/interopRequireWildcard.js +19 -21
  58. package/dist/babel_helpers/isNativeFunction/isNativeFunction.js +2 -2
  59. package/dist/babel_helpers/isNativeReflectConstruct/isNativeReflectConstruct.js +7 -7
  60. package/dist/babel_helpers/iterableToArray/iterableToArray.js +6 -2
  61. package/dist/babel_helpers/iterableToArrayLimit/iterableToArrayLimit.js +6 -1
  62. package/dist/babel_helpers/iterableToArrayLimitLoose/iterableToArrayLimitLoose.js +6 -2
  63. package/dist/babel_helpers/jsx/jsx.js +14 -7
  64. package/dist/babel_helpers/maybeArrayLike/maybeArrayLike.js +6 -5
  65. package/dist/babel_helpers/newArrowCheck/newArrowCheck.js +2 -2
  66. package/dist/babel_helpers/nonIterableRest/nonIterableRest.js +5 -3
  67. package/dist/babel_helpers/nonIterableSpread/nonIterableSpread.js +5 -3
  68. package/dist/babel_helpers/objectDestructuringEmpty/objectDestructuringEmpty.js +2 -2
  69. package/dist/babel_helpers/objectSpread/objectSpread.js +15 -12
  70. package/dist/babel_helpers/objectSpread2/objectSpread2.js +7 -2
  71. package/dist/babel_helpers/objectWithoutProperties/objectWithoutProperties.js +15 -13
  72. package/dist/babel_helpers/objectWithoutPropertiesLoose/objectWithoutPropertiesLoose.js +11 -11
  73. package/dist/babel_helpers/possibleConstructorReturn/possibleConstructorReturn.js +7 -6
  74. package/dist/babel_helpers/readOnlyError/readOnlyError.js +2 -2
  75. package/dist/babel_helpers/regeneratorRuntime/regeneratorRuntime.js +124 -73
  76. package/dist/babel_helpers/set/set.js +23 -20
  77. package/dist/babel_helpers/setPrototypeOf/setPrototypeOf.js +6 -5
  78. package/dist/babel_helpers/skipFirstGeneratorNext/skipFirstGeneratorNext.js +5 -5
  79. package/dist/babel_helpers/slicedToArray/slicedToArray.js +10 -5
  80. package/dist/babel_helpers/slicedToArrayLoose/slicedToArrayLoose.js +12 -6
  81. package/dist/babel_helpers/superPropBase/superPropBase.js +6 -5
  82. package/dist/babel_helpers/taggedTemplateLiteral/taggedTemplateLiteral.js +7 -7
  83. package/dist/babel_helpers/taggedTemplateLiteralLoose/taggedTemplateLiteralLoose.js +4 -4
  84. package/dist/babel_helpers/tdz/tdz.js +2 -2
  85. package/dist/babel_helpers/temporalRef/temporalRef.js +5 -4
  86. package/dist/babel_helpers/temporalUndefined/temporalUndefined.js +1 -1
  87. package/dist/babel_helpers/toArray/toArray.js +10 -5
  88. package/dist/babel_helpers/toConsumableArray/toConsumableArray.js +10 -5
  89. package/dist/babel_helpers/toPrimitive/toPrimitive.js +7 -7
  90. package/dist/babel_helpers/toPropertyKey/toPropertyKey.js +5 -4
  91. package/dist/babel_helpers/typeof/typeof.js +14 -5
  92. package/dist/babel_helpers/unsupportedIterableToArray/unsupportedIterableToArray.js +10 -8
  93. package/dist/babel_helpers/wrapAsyncGenerator/wrapAsyncGenerator.js +5 -4
  94. package/dist/babel_helpers/wrapNativeSuper/wrapNativeSuper.js +17 -15
  95. package/dist/babel_helpers/wrapRegExp/wrapRegExp.js +19 -8
  96. package/dist/babel_helpers/writeOnlyError/writeOnlyError.js +2 -2
  97. package/dist/js/autoreload.js +148 -133
  98. package/dist/js/import_meta_hot.js +19 -13
  99. package/dist/js/inline_content.js +1 -3
  100. package/dist/js/new_stylesheet.js +119 -60
  101. package/dist/js/regenerator_runtime.js +204 -102
  102. package/dist/js/ribbon.js +11 -6
  103. package/dist/js/server_events_client.js +122 -98
  104. package/dist/js/ws.js +968 -265
  105. package/dist/jsenv_core.js +8513 -6162
  106. package/package.json +9 -9
  107. package/src/build/build.js +497 -486
  108. package/src/build/version_mappings_injection.js +21 -44
  109. package/src/kitchen/errors.js +2 -2
  110. package/src/kitchen/fetched_content_compliance.js +6 -2
  111. package/src/kitchen/kitchen.js +285 -80
  112. package/src/kitchen/prepend_content.js +135 -0
  113. package/src/kitchen/url_graph/url_graph_visitor.js +99 -0
  114. package/src/kitchen/url_graph/url_info_transformations.js +140 -21
  115. package/src/kitchen/url_graph.js +59 -29
  116. package/src/plugins/autoreload/jsenv_plugin_hmr.js +1 -2
  117. package/src/plugins/import_meta_hot/jsenv_plugin_import_meta_hot.js +2 -2
  118. package/src/plugins/importmap/jsenv_plugin_importmap.js +2 -2
  119. package/src/plugins/inlining/jsenv_plugin_inlining_as_data_url.js +1 -1
  120. package/src/plugins/reference_analysis/html/jsenv_plugin_html_reference_analysis.js +44 -23
  121. package/src/plugins/reference_analysis/js/jsenv_plugin_js_reference_analysis.js +2 -1
  122. package/dist/js/global_this_js_classic.js +0 -24
  123. package/dist/js/global_this_js_module.js +0 -20
  124. package/src/build/graph_utils.js +0 -34
@@ -1,10 +1,12 @@
1
1
  /* @minVersion 7.0.0-beta.0 */
2
2
 
3
3
  import OverloadYield from "../overloadYield/overloadYield.js";
4
+
4
5
  export default function _asyncGeneratorDelegate(inner) {
5
6
  var iter = {},
6
7
  // See the comment in AsyncGenerator to understand what this is.
7
8
  waiting = false;
9
+
8
10
  function pump(key, value) {
9
11
  waiting = true;
10
12
  value = new Promise(function (resolve) {
@@ -12,12 +14,15 @@ export default function _asyncGeneratorDelegate(inner) {
12
14
  });
13
15
  return {
14
16
  done: false,
15
- value: new OverloadYield(value, /* kind: delegate */1)
17
+ value: new OverloadYield(value, /* kind: delegate */ 1),
16
18
  };
17
19
  }
18
- iter[typeof Symbol !== "undefined" && Symbol.iterator || "@@iterator"] = function () {
19
- return this;
20
- };
20
+
21
+ iter[(typeof Symbol !== "undefined" && Symbol.iterator) || "@@iterator"] =
22
+ function () {
23
+ return this;
24
+ };
25
+
21
26
  iter.next = function (value) {
22
27
  if (waiting) {
23
28
  waiting = false;
@@ -25,6 +30,7 @@ export default function _asyncGeneratorDelegate(inner) {
25
30
  }
26
31
  return pump("next", value);
27
32
  };
33
+
28
34
  if (typeof inner.throw === "function") {
29
35
  iter.throw = function (value) {
30
36
  if (waiting) {
@@ -34,6 +40,7 @@ export default function _asyncGeneratorDelegate(inner) {
34
40
  return pump("throw", value);
35
41
  };
36
42
  }
43
+
37
44
  if (typeof inner.return === "function") {
38
45
  iter.return = function (value) {
39
46
  if (waiting) {
@@ -43,5 +50,6 @@ export default function _asyncGeneratorDelegate(inner) {
43
50
  return pump("return", value);
44
51
  };
45
52
  }
53
+
46
54
  return iter;
47
55
  }
@@ -3,10 +3,12 @@ export default function _asyncIterator(iterable) {
3
3
  async,
4
4
  sync,
5
5
  retry = 2;
6
+
6
7
  if (typeof Symbol !== "undefined") {
7
8
  async = Symbol.asyncIterator;
8
9
  sync = Symbol.iterator;
9
10
  }
11
+
10
12
  while (retry--) {
11
13
  if (async && (method = iterable[async]) != null) {
12
14
  return method.call(iterable);
@@ -14,29 +16,29 @@ export default function _asyncIterator(iterable) {
14
16
  if (sync && (method = iterable[sync]) != null) {
15
17
  return new AsyncFromSyncIterator(method.call(iterable));
16
18
  }
19
+
17
20
  async = "@@asyncIterator";
18
21
  sync = "@@iterator";
19
22
  }
23
+
20
24
  throw new TypeError("Object is not async iterable");
21
25
  }
26
+
22
27
  function AsyncFromSyncIterator(s) {
23
28
  AsyncFromSyncIterator = function (s) {
24
29
  this.s = s;
25
30
  this.n = s.next;
26
31
  };
27
32
  AsyncFromSyncIterator.prototype = {
28
- /* SyncIterator */s: null,
29
- /* SyncIterator.[[Next]] */n: null,
33
+ /* SyncIterator */ s: null,
34
+ /* SyncIterator.[[Next]] */ n: null,
30
35
  next: function () {
31
36
  return AsyncFromSyncIteratorContinuation(this.n.apply(this.s, arguments));
32
37
  },
33
38
  return: function (value) {
34
39
  var ret = this.s.return;
35
40
  if (ret === undefined) {
36
- return Promise.resolve({
37
- value: value,
38
- done: true
39
- });
41
+ return Promise.resolve({ value: value, done: true });
40
42
  }
41
43
  return AsyncFromSyncIteratorContinuation(ret.apply(this.s, arguments));
42
44
  },
@@ -44,20 +46,20 @@ function AsyncFromSyncIterator(s) {
44
46
  var thr = this.s.return;
45
47
  if (thr === undefined) return Promise.reject(value);
46
48
  return AsyncFromSyncIteratorContinuation(thr.apply(this.s, arguments));
47
- }
49
+ },
48
50
  };
51
+
49
52
  function AsyncFromSyncIteratorContinuation(r) {
50
53
  // This step is _before_ calling AsyncFromSyncIteratorContinuation in the spec.
51
54
  if (Object(r) !== r) {
52
55
  return Promise.reject(new TypeError(r + " is not an object."));
53
56
  }
57
+
54
58
  var done = r.done;
55
59
  return Promise.resolve(r.value).then(function (value) {
56
- return {
57
- value: value,
58
- done: done
59
- };
60
+ return { value: value, done: done };
60
61
  });
61
62
  }
63
+
62
64
  return new AsyncFromSyncIterator(s);
63
65
  }
@@ -1,33 +1,34 @@
1
1
  export default function (fn) {
2
2
  return function () {
3
- var self = this;
3
+ var self = this
4
4
  // eslint-disable-next-line prefer-rest-params
5
- var args = arguments;
5
+ var args = arguments
6
6
  return new Promise(function (resolve, reject) {
7
- var gen = fn.apply(self, args);
7
+ var gen = fn.apply(self, args)
8
8
  function _next(value) {
9
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);
9
+ asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value)
10
10
  }
11
11
  function _throw(err) {
12
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);
12
+ asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err)
13
13
  }
14
- _next(undefined);
15
- });
16
- };
14
+ _next(undefined)
15
+ })
16
+ }
17
17
  }
18
+
18
19
  const asyncGeneratorStep = (gen, resolve, reject, _next, _throw, key, arg) => {
19
- var info;
20
- var value;
20
+ var info
21
+ var value
21
22
  try {
22
- info = gen[key](arg);
23
- value = info.value;
23
+ info = gen[key](arg)
24
+ value = info.value
24
25
  } catch (error) {
25
- reject(error);
26
- return;
26
+ reject(error)
27
+ return
27
28
  }
28
29
  if (info.done) {
29
- resolve(value);
30
+ resolve(value)
30
31
  } else {
31
- Promise.resolve(value).then(_next, _throw);
32
+ Promise.resolve(value).then(_next, _throw)
32
33
  }
33
- };
34
+ }
@@ -1,4 +1,5 @@
1
1
  import OverloadYield from "../overloadYield/overloadYield.js";
2
+
2
3
  export default function _awaitAsyncGenerator(value) {
3
- return new OverloadYield(value, /* kind: await */0);
4
+ return new OverloadYield(value, /* kind: await */ 0);
4
5
  }
@@ -1,6 +1,9 @@
1
1
  export default function _checkInRHS(value) {
2
- if (Object(value) !== value) {
3
- throw TypeError("right-hand side of 'in' should be an object, got " + (value !== null ? typeof value : "null"));
4
- }
5
- return value;
6
- }
2
+ if (Object(value) !== value) {
3
+ throw TypeError(
4
+ "right-hand side of 'in' should be an object, got " +
5
+ (value !== null ? typeof value : "null")
6
+ );
7
+ }
8
+ return value;
9
+ }
@@ -4,17 +4,17 @@ export default function _classApplyDescriptorDestructureSet(receiver, descriptor
4
4
  descriptor.__destrObj = {
5
5
  // eslint-disable-next-line accessor-pairs
6
6
  set value(v) {
7
- descriptor.set.call(receiver, v);
8
- }
9
- };
7
+ descriptor.set.call(receiver, v)
8
+ },
9
+ }
10
10
  }
11
- return descriptor.__destrObj;
11
+ return descriptor.__destrObj
12
12
  }
13
13
  if (!descriptor.writable) {
14
14
  // This should only throw in strict mode, but class bodies are
15
15
  // always strict and private fields can only be used inside
16
16
  // class bodies.
17
- throw new TypeError("attempted to set read only private field");
17
+ throw new TypeError("attempted to set read only private field")
18
18
  }
19
- return descriptor;
20
- }
19
+ return descriptor
20
+ }
@@ -1,6 +1,6 @@
1
1
  export default function _classApplyDescriptorGet(receiver, descriptor) {
2
2
  if (descriptor.get) {
3
- return descriptor.get.call(receiver);
3
+ return descriptor.get.call(receiver)
4
4
  }
5
- return descriptor.value;
6
- }
5
+ return descriptor.value
6
+ }
@@ -1,13 +1,13 @@
1
1
  export default function _classApplyDescriptorSet(receiver, descriptor, value) {
2
2
  if (descriptor.set) {
3
- descriptor.set.call(receiver, value);
3
+ descriptor.set.call(receiver, value)
4
4
  } else {
5
5
  if (!descriptor.writable) {
6
6
  // This should only throw in strict mode, but class bodies are
7
7
  // always strict and private fields can only be used inside
8
8
  // class bodies.
9
- throw new TypeError("attempted to set read only private field");
9
+ throw new TypeError("attempted to set read only private field")
10
10
  }
11
- descriptor.value = value;
11
+ descriptor.value = value
12
12
  }
13
- }
13
+ }
@@ -1,5 +1,5 @@
1
1
  export default function _classCallCheck(instance, Constructor) {
2
2
  if (!(instance instanceof Constructor)) {
3
- throw new TypeError("Cannot call a class as a function");
3
+ throw new TypeError("Cannot call a class as a function")
4
4
  }
5
- }
5
+ }
@@ -1,5 +1,5 @@
1
1
  export default function _classCheckPrivateStaticAccess(receiver, classConstructor) {
2
2
  if (receiver !== classConstructor) {
3
- throw new TypeError("Private static access of wrong provenance");
3
+ throw new TypeError("Private static access of wrong provenance")
4
4
  }
5
- }
5
+ }
@@ -1,6 +1,6 @@
1
1
  export default function _classCheckPrivateStaticFieldDescriptor(descriptor, action) {
2
2
  if (descriptor === undefined) {
3
3
  // eslint-disable-next-line prefer-template
4
- throw new TypeError("attempted to " + action + " private static field before its declaration");
4
+ throw new TypeError("attempted to " + action + " private static field before its declaration")
5
5
  }
6
- }
6
+ }
@@ -1,7 +1,7 @@
1
1
  export default function _classExtractFieldDescriptor(receiver, privateMap, action) {
2
2
  if (!privateMap.has(receiver)) {
3
3
  // eslint-disable-next-line prefer-template
4
- throw new TypeError("attempted to " + action + " private field on non-instance");
4
+ throw new TypeError("attempted to " + action + " private field on non-instance")
5
5
  }
6
- return privateMap.get(receiver);
7
- }
6
+ return privateMap.get(receiver)
7
+ }
@@ -1,4 +1,4 @@
1
1
  export default function _classNameTDZError(name) {
2
2
  // eslint-disable-next-line prefer-template
3
- throw new ReferenceError("Class " + name + "cannot be referenced in computed property keys.");
4
- }
3
+ throw new ReferenceError("Class " + name + "cannot be referenced in computed property keys.")
4
+ }
@@ -1,6 +1,7 @@
1
- import classApplyDescriptorDestructureSet from "../classApplyDescriptorDestructureSet/classApplyDescriptorDestructureSet.js";
2
- import classExtractFieldDescriptor from "../classExtractFieldDescriptor/classExtractFieldDescriptor.js";
1
+ import classApplyDescriptorDestructureSet from "../classApplyDescriptorDestructureSet/classApplyDescriptorDestructureSet.js"
2
+ import classExtractFieldDescriptor from "../classExtractFieldDescriptor/classExtractFieldDescriptor.js"
3
+
3
4
  export default function (receiver, privateMap) {
4
- var descriptor = classExtractFieldDescriptor(receiver, privateMap, "set");
5
- return classApplyDescriptorDestructureSet(receiver, descriptor);
6
- }
5
+ var descriptor = classExtractFieldDescriptor(receiver, privateMap, "set")
6
+ return classApplyDescriptorDestructureSet(receiver, descriptor)
7
+ }
@@ -1,6 +1,7 @@
1
- import classApplyDescriptorGet from "../classApplyDescriptorGet/classApplyDescriptorGet.js";
2
- import classExtractFieldDescriptor from "../classExtractFieldDescriptor/classExtractFieldDescriptor.js";
1
+ import classApplyDescriptorGet from "../classApplyDescriptorGet/classApplyDescriptorGet.js"
2
+ import classExtractFieldDescriptor from "../classExtractFieldDescriptor/classExtractFieldDescriptor.js"
3
+
3
4
  export default function (receiver, privateMap) {
4
- var descriptor = classExtractFieldDescriptor(receiver, privateMap, "get");
5
- return classApplyDescriptorGet(receiver, descriptor);
6
- }
5
+ var descriptor = classExtractFieldDescriptor(receiver, privateMap, "get")
6
+ return classApplyDescriptorGet(receiver, descriptor)
7
+ }
@@ -1,6 +1,6 @@
1
1
  export default function (receiver, privateKey) {
2
2
  if (!Object.prototype.hasOwnProperty.call(receiver, privateKey)) {
3
- throw new TypeError("attempted to use private field on non-instance");
3
+ throw new TypeError("attempted to use private field on non-instance")
4
4
  }
5
- return receiver;
6
- }
5
+ return receiver
6
+ }
@@ -1,5 +1,5 @@
1
- var id = 0;
1
+ var id = 0
2
2
  export default function (name) {
3
3
  // eslint-disable-next-line prefer-template
4
- return "__private_" + id++ + "_" + name;
5
- }
4
+ return "__private_" + id++ + "_" + name
5
+ }
@@ -1,7 +1,8 @@
1
- import classApplyDescriptorSet from "../classApplyDescriptorSet/classApplyDescriptorSet.js";
2
- import classExtractFieldDescriptor from "../classExtractFieldDescriptor/classExtractFieldDescriptor.js";
1
+ import classApplyDescriptorSet from "../classApplyDescriptorSet/classApplyDescriptorSet.js"
2
+ import classExtractFieldDescriptor from "../classExtractFieldDescriptor/classExtractFieldDescriptor.js"
3
+
3
4
  export default function (receiver, privateMap, value) {
4
- var descriptor = classExtractFieldDescriptor(receiver, privateMap, "set");
5
- classApplyDescriptorSet(receiver, descriptor, value);
6
- return value;
7
- }
5
+ var descriptor = classExtractFieldDescriptor(receiver, privateMap, "set")
6
+ classApplyDescriptorSet(receiver, descriptor, value)
7
+ return value
8
+ }
@@ -1,6 +1,6 @@
1
1
  export default function _classPrivateMethodGet(receiver, privateSet, fn) {
2
2
  if (!privateSet.has(receiver)) {
3
- throw new TypeError("attempted to get private field on non-instance");
3
+ throw new TypeError("attempted to get private field on non-instance")
4
4
  }
5
- return fn;
6
- }
5
+ return fn
6
+ }
@@ -1,3 +1,3 @@
1
1
  export default function _classStaticPrivateMethodSet() {
2
- throw new TypeError("attempted to set read only static private field");
3
- }
2
+ throw new TypeError("attempted to set read only static private field")
3
+ }
@@ -1,8 +1,9 @@
1
- import classApplyDescriptorGet from "../classApplyDescriptorGet/classApplyDescriptorGet.js";
2
- import classCheckPrivateStaticAccess from "../classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js";
3
- import classCheckPrivateStaticFieldDescriptor from "../classCheckPrivateStaticFieldDescriptor/classCheckPrivateStaticFieldDescriptor.js";
1
+ import classApplyDescriptorGet from "../classApplyDescriptorGet/classApplyDescriptorGet.js"
2
+ import classCheckPrivateStaticAccess from "../classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js"
3
+ import classCheckPrivateStaticFieldDescriptor from "../classCheckPrivateStaticFieldDescriptor/classCheckPrivateStaticFieldDescriptor.js"
4
+
4
5
  export default function _classStaticPrivateFieldSpecGet(receiver, classConstructor, descriptor) {
5
- classCheckPrivateStaticAccess(receiver, classConstructor);
6
- classCheckPrivateStaticFieldDescriptor(descriptor, "get");
7
- return classApplyDescriptorGet(receiver, descriptor);
8
- }
6
+ classCheckPrivateStaticAccess(receiver, classConstructor)
7
+ classCheckPrivateStaticFieldDescriptor(descriptor, "get")
8
+ return classApplyDescriptorGet(receiver, descriptor)
9
+ }
@@ -1,9 +1,15 @@
1
- import classApplyDescriptorSet from "../classApplyDescriptorSet/classApplyDescriptorSet.js";
2
- import classCheckPrivateStaticAccess from "../classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js";
3
- import classCheckPrivateStaticFieldDescriptor from "../classCheckPrivateStaticFieldDescriptor/classCheckPrivateStaticFieldDescriptor.js";
4
- export default function _classStaticPrivateFieldSpecSet(receiver, classConstructor, descriptor, value) {
5
- classCheckPrivateStaticAccess(receiver, classConstructor);
6
- classCheckPrivateStaticFieldDescriptor(descriptor, "set");
7
- classApplyDescriptorSet(receiver, descriptor, value);
8
- return value;
9
- }
1
+ import classApplyDescriptorSet from "../classApplyDescriptorSet/classApplyDescriptorSet.js"
2
+ import classCheckPrivateStaticAccess from "../classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js"
3
+ import classCheckPrivateStaticFieldDescriptor from "../classCheckPrivateStaticFieldDescriptor/classCheckPrivateStaticFieldDescriptor.js"
4
+
5
+ export default function _classStaticPrivateFieldSpecSet(
6
+ receiver,
7
+ classConstructor,
8
+ descriptor,
9
+ value,
10
+ ) {
11
+ classCheckPrivateStaticAccess(receiver, classConstructor)
12
+ classCheckPrivateStaticFieldDescriptor(descriptor, "set")
13
+ classApplyDescriptorSet(receiver, descriptor, value)
14
+ return value
15
+ }
@@ -1,5 +1,6 @@
1
- import classCheckPrivateStaticAccess from "../classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js";
1
+ import classCheckPrivateStaticAccess from "../classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js"
2
+
2
3
  export default function _classStaticPrivateMethodGet(receiver, classConstructor, method) {
3
- classCheckPrivateStaticAccess(receiver, classConstructor);
4
- return method;
5
- }
4
+ classCheckPrivateStaticAccess(receiver, classConstructor)
5
+ return method
6
+ }
@@ -1,3 +1,3 @@
1
1
  export default function _classStaticPrivateMethodSet() {
2
- throw new TypeError("attempted to set read only static private field");
3
- }
2
+ throw new TypeError("attempted to set read only static private field")
3
+ }
@@ -1,15 +1,16 @@
1
- import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js";
2
- import isNativeReflectConstruct from "../isNativeReflectConstruct/isNativeReflectConstruct.js";
1
+ import setPrototypeOf from "../setPrototypeOf/setPrototypeOf.js"
2
+ import isNativeReflectConstruct from "../isNativeReflectConstruct/isNativeReflectConstruct.js"
3
3
 
4
4
  // NOTE: If Parent !== Class, the correct __proto__ is set *after*
5
5
  // calling the constructor.
6
6
  function reflectConstruct(Parent, args, Class) {
7
- var a = [null];
7
+ var a = [null]
8
8
  // eslint-disable-next-line prefer-spread
9
- a.push.apply(a, args);
10
- var Constructor = Function.bind.apply(Parent, a);
11
- var instance = new Constructor();
12
- if (Class) setPrototypeOf(instance, Class.prototype);
13
- return instance;
9
+ a.push.apply(a, args)
10
+ var Constructor = Function.bind.apply(Parent, a)
11
+ var instance = new Constructor()
12
+ if (Class) setPrototypeOf(instance, Class.prototype)
13
+ return instance
14
14
  }
15
- export default isNativeReflectConstruct() ? Reflect.construct.bind() : reflectConstruct;
15
+
16
+ export default isNativeReflectConstruct() ? Reflect.construct.bind() : reflectConstruct
@@ -1,4 +1,5 @@
1
1
  import toPropertyKey from "../toPropertyKey/toPropertyKey.js";
2
+
2
3
  function _defineProperties(target, props) {
3
4
  for (var i = 0; i < props.length; i++) {
4
5
  var descriptor = props[i];
@@ -11,8 +12,6 @@ function _defineProperties(target, props) {
11
12
  export default function _createClass(Constructor, protoProps, staticProps) {
12
13
  if (protoProps) _defineProperties(Constructor.prototype, protoProps);
13
14
  if (staticProps) _defineProperties(Constructor, staticProps);
14
- Object.defineProperty(Constructor, "prototype", {
15
- writable: false
16
- });
15
+ Object.defineProperty(Constructor, "prototype", { writable: false });
17
16
  return Constructor;
18
17
  }
@@ -1,59 +1,60 @@
1
1
  /* eslint-disable eqeqeq, no-eq-null */
2
- import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js";
2
+ import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js"
3
3
 
4
4
  // s: start (create the iterator)
5
5
  // n: next
6
6
  // e: error (called whenever something throws)
7
7
  // f: finish (always called at the end)
8
8
  export default function _createForOfIteratorHelper(o, allowArrayLike) {
9
- var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
9
+ var it = (typeof Symbol !== "undefined" && o[Symbol.iterator]) || o["@@iterator"]
10
10
  if (!it) {
11
11
  // Fallback for engines without symbol support
12
- if (Array.isArray(o) || (it = unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
13
- if (it) o = it;
14
- var i = 0;
15
- var F = function () {};
12
+ if (
13
+ Array.isArray(o) ||
14
+ (it = unsupportedIterableToArray(o)) ||
15
+ (allowArrayLike && o && typeof o.length === "number")
16
+ ) {
17
+ if (it) o = it
18
+ var i = 0
19
+ var F = function () {}
16
20
  return {
17
21
  s: F,
18
22
  n: function () {
19
- if (i >= o.length) return {
20
- done: true
21
- };
22
- return {
23
- done: false,
24
- value: o[i++]
25
- };
23
+ if (i >= o.length) return { done: true }
24
+ return { done: false, value: o[i++] }
26
25
  },
27
26
  e: function (e) {
28
- throw e;
27
+ throw e
29
28
  },
30
- f: F
31
- };
29
+ f: F,
30
+ }
32
31
  }
33
- throw new TypeError("Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
32
+ throw new TypeError(
33
+ "Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.",
34
+ )
34
35
  }
35
36
  var normalCompletion = true,
36
37
  didErr = false,
37
- err;
38
+ err
38
39
  return {
39
40
  s: function () {
40
- it = it.call(o);
41
+ it = it.call(o)
41
42
  },
42
43
  n: function () {
43
- var step = it.next();
44
- normalCompletion = step.done;
45
- return step;
44
+ var step = it.next()
45
+ normalCompletion = step.done
46
+ return step
46
47
  },
47
48
  e: function (e) {
48
- didErr = true;
49
- err = e;
49
+ didErr = true
50
+ err = e
50
51
  },
51
52
  f: function () {
52
53
  try {
53
- if (!normalCompletion && it.return != null) it.return();
54
+ if (!normalCompletion && it.return != null) it.return()
54
55
  } finally {
55
- if (didErr) throw err;
56
+ if (didErr) throw err
56
57
  }
57
- }
58
- };
59
- }
58
+ },
59
+ }
60
+ }
@@ -1,21 +1,23 @@
1
1
  /* eslint-disable eqeqeq, no-eq-null */
2
- import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js";
2
+ import unsupportedIterableToArray from "../unsupportedIterableToArray/unsupportedIterableToArray.js"
3
+
3
4
  export default function _createForOfIteratorHelperLoose(o, allowArrayLike) {
4
- var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
5
- if (it) return (it = it.call(o)).next.bind(it);
5
+ var it = (typeof Symbol !== "undefined" && o[Symbol.iterator]) || o["@@iterator"]
6
+ if (it) return (it = it.call(o)).next.bind(it)
6
7
  // Fallback for engines without symbol support
7
- if (Array.isArray(o) || (it = unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
8
- if (it) o = it;
9
- var i = 0;
8
+ if (
9
+ Array.isArray(o) ||
10
+ (it = unsupportedIterableToArray(o)) ||
11
+ (allowArrayLike && o && typeof o.length === "number")
12
+ ) {
13
+ if (it) o = it
14
+ var i = 0
10
15
  return function () {
11
- if (i >= o.length) return {
12
- done: true
13
- };
14
- return {
15
- done: false,
16
- value: o[i++]
17
- };
18
- };
16
+ if (i >= o.length) return { done: true }
17
+ return { done: false, value: o[i++] }
18
+ }
19
19
  }
20
- throw new TypeError("Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
21
- }
20
+ throw new TypeError(
21
+ "Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.",
22
+ )
23
+ }