sample-piral 0.14.20-beta.3989 → 0.14.20-beta.4013

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.
@@ -754,6 +754,28 @@ __webpack_require__.r(__webpack_exports__);
754
754
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
755
755
  /* harmony export */ "cleanup": () => (/* binding */ cleanup)
756
756
  /* harmony export */ });
757
+ /* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./utils */ "../../framework/piral-base/esm/utils.js");
758
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
759
+
760
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
761
+
762
+ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
763
+
764
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
765
+
766
+ function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
767
+
768
+ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
769
+
770
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
771
+
772
+ function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
773
+
774
+ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
775
+
776
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
777
+
778
+
757
779
  function cleanup(pilet) {
758
780
  var css = document.querySelector("link[data-origin=".concat(JSON.stringify(pilet.name), "]"));
759
781
  css === null || css === void 0 ? void 0 : css.remove(); // check if this was actually set up using a require reference
@@ -761,6 +783,26 @@ function cleanup(pilet) {
761
783
  if ('requireRef' in pilet) {
762
784
  var depName = pilet.requireRef;
763
785
  delete window[depName];
786
+ } // remove the pilet's evaluated modules from SystemJS (except the shared dependencies)
787
+
788
+
789
+ if ('link' in pilet) {
790
+ var basePath = (0,_utils__WEBPACK_IMPORTED_MODULE_0__.getBasePath)(pilet.link);
791
+ var dependencies = Object.keys(pilet.dependencies || {}).map(function (m) {
792
+ return pilet.dependencies[m];
793
+ });
794
+
795
+ _toConsumableArray(System.entries()).filter(function (_ref) {
796
+ var _ref2 = _slicedToArray(_ref, 1),
797
+ id = _ref2[0];
798
+
799
+ return id.startsWith(basePath) && !dependencies.includes(id);
800
+ }).forEach(function (_ref3) {
801
+ var _ref4 = _slicedToArray(_ref3, 1),
802
+ id = _ref4[0];
803
+
804
+ return System["delete"](id);
805
+ });
764
806
  }
765
807
  }
766
808
 
@@ -3643,7 +3685,7 @@ function createInstance() {
3643
3685
  var createApi = apiFactory(context, usedPlugins);
3644
3686
  var root = createApi({
3645
3687
  name: 'root',
3646
- version: "0.14.20-beta.3989" || 0,
3688
+ version: "0.14.20-beta.4013" || 0,
3647
3689
  spec: ''
3648
3690
  });
3649
3691
  var options = (0,_helpers__WEBPACK_IMPORTED_MODULE_6__.createPiletOptions)({
@@ -9512,11 +9554,11 @@ function installPiralDebug(options) {
9512
9554
  debug: debugApiVersion,
9513
9555
  instance: {
9514
9556
  name: "sample-piral",
9515
- version: "0.14.20-beta.3989",
9557
+ version: "0.14.20-beta.4013",
9516
9558
  dependencies: "reactstrap,react,react-dom,react-router,react-router-dom,history,tslib,path-to-regexp,@libre/atom,@dbeining/react-atom"
9517
9559
  },
9518
9560
  build: {
9519
- date: "2022-03-24T03:55:42.918Z",
9561
+ date: "2022-03-30T21:13:25.640Z",
9520
9562
  cli: "0.14.19",
9521
9563
  compat: "0.14"
9522
9564
  },
@@ -80930,4 +80972,4 @@ var layout_1 = __webpack_require__(/*! ./layout */ "./src/layout.tsx");
80930
80972
 
80931
80973
  /******/ })()
80932
80974
  ;
80933
- //# sourceMappingURL=index.c242d3.js.map
80975
+ //# sourceMappingURL=index.d6a55c.js.map