diff --git a/test/cases/auxiliaryAssets/expected/webpack-5-importModule/auxiliaryAssets-815babffe97b00a1f30b.woff2 b/test/cases/auxiliaryAssets/expected/auxiliaryAssets-815babffe97b00a1f30b.woff2 similarity index 100% rename from test/cases/auxiliaryAssets/expected/webpack-5-importModule/auxiliaryAssets-815babffe97b00a1f30b.woff2 rename to test/cases/auxiliaryAssets/expected/auxiliaryAssets-815babffe97b00a1f30b.woff2 diff --git a/test/cases/auxiliaryAssets/expected/webpack-5-importModule/auxiliaryAssets-a0de923c946d4ccb38b0.ttf b/test/cases/auxiliaryAssets/expected/auxiliaryAssets-a0de923c946d4ccb38b0.ttf similarity index 100% rename from test/cases/auxiliaryAssets/expected/webpack-5-importModule/auxiliaryAssets-a0de923c946d4ccb38b0.ttf rename to test/cases/auxiliaryAssets/expected/auxiliaryAssets-a0de923c946d4ccb38b0.ttf diff --git a/test/cases/auxiliaryAssets/expected/webpack-5-importModule/auxiliaryAssets-d4c409dfe110747b1763.woff b/test/cases/auxiliaryAssets/expected/auxiliaryAssets-d4c409dfe110747b1763.woff similarity index 100% rename from test/cases/auxiliaryAssets/expected/webpack-5-importModule/auxiliaryAssets-d4c409dfe110747b1763.woff rename to test/cases/auxiliaryAssets/expected/auxiliaryAssets-d4c409dfe110747b1763.woff diff --git a/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-815babffe97b00a1f30b.woff2 b/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-815babffe97b00a1f30b.woff2 deleted file mode 100644 index ddca5526..00000000 --- a/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-815babffe97b00a1f30b.woff2 +++ /dev/null @@ -1 +0,0 @@ -auxiliaryAssets-815babffe97b00a1f30b.woff2 \ No newline at end of file diff --git a/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-a0de923c946d4ccb38b0.ttf b/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-a0de923c946d4ccb38b0.ttf deleted file mode 100644 index 16502c45..00000000 --- a/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-a0de923c946d4ccb38b0.ttf +++ /dev/null @@ -1 +0,0 @@ -auxiliaryAssets-a0de923c946d4ccb38b0.ttf \ No newline at end of file diff --git a/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-d4c409dfe110747b1763.woff b/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-d4c409dfe110747b1763.woff deleted file mode 100644 index deeb500c..00000000 --- a/test/cases/auxiliaryAssets/expected/webpack-5/auxiliaryAssets-d4c409dfe110747b1763.woff +++ /dev/null @@ -1 +0,0 @@ -auxiliaryAssets-d4c409dfe110747b1763.woff \ No newline at end of file diff --git a/test/cases/chunkFilename-as-function/expected/webpack-5-importModule/0.async.css b/test/cases/chunkFilename-as-function/expected/0.async.css similarity index 100% rename from test/cases/chunkFilename-as-function/expected/webpack-5-importModule/0.async.css rename to test/cases/chunkFilename-as-function/expected/0.async.css diff --git a/test/cases/chunkFilename-as-function/expected/webpack-5-importModule/main.css b/test/cases/chunkFilename-as-function/expected/main.css similarity index 100% rename from test/cases/chunkFilename-as-function/expected/webpack-5-importModule/main.css rename to test/cases/chunkFilename-as-function/expected/main.css diff --git a/test/cases/chunkFilename-as-function/expected/webpack-5/0.async.css b/test/cases/chunkFilename/expected/0.async.css similarity index 100% rename from test/cases/chunkFilename-as-function/expected/webpack-5/0.async.css rename to test/cases/chunkFilename/expected/0.async.css diff --git a/test/cases/chunkFilename-as-function/expected/webpack-5/main.css b/test/cases/chunkFilename/expected/main.css similarity index 100% rename from test/cases/chunkFilename-as-function/expected/webpack-5/main.css rename to test/cases/chunkFilename/expected/main.css diff --git a/test/cases/chunkFilename/expected/webpack-5-importModule/0.async.css b/test/cases/chunkFilename/expected/webpack-5-importModule/0.async.css deleted file mode 100644 index e665100a..00000000 --- a/test/cases/chunkFilename/expected/webpack-5-importModule/0.async.css +++ /dev/null @@ -1,4 +0,0 @@ -.async { - color: red; -} - diff --git a/test/cases/chunkFilename/expected/webpack-5/0.async.css b/test/cases/chunkFilename/expected/webpack-5/0.async.css deleted file mode 100644 index e665100a..00000000 --- a/test/cases/chunkFilename/expected/webpack-5/0.async.css +++ /dev/null @@ -1,4 +0,0 @@ -.async { - color: red; -} - diff --git a/test/cases/contenthash-multiple-entries/expected/webpack-5-importModule/1cd4a7654bac4107104f.css b/test/cases/contenthash-multiple-entries/expected/1cd4a7654bac4107104f.css similarity index 100% rename from test/cases/contenthash-multiple-entries/expected/webpack-5-importModule/1cd4a7654bac4107104f.css rename to test/cases/contenthash-multiple-entries/expected/1cd4a7654bac4107104f.css diff --git a/test/cases/contenthash-multiple-entries/expected/webpack-5-importModule/788f5dc856f2e114b45c.css b/test/cases/contenthash-multiple-entries/expected/788f5dc856f2e114b45c.css similarity index 100% rename from test/cases/contenthash-multiple-entries/expected/webpack-5-importModule/788f5dc856f2e114b45c.css rename to test/cases/contenthash-multiple-entries/expected/788f5dc856f2e114b45c.css diff --git a/test/cases/contenthash-multiple-entries/expected/webpack-5/1cd4a7654bac4107104f.css b/test/cases/contenthash-multiple-entries/expected/webpack-5/1cd4a7654bac4107104f.css deleted file mode 100644 index c6856116..00000000 --- a/test/cases/contenthash-multiple-entries/expected/webpack-5/1cd4a7654bac4107104f.css +++ /dev/null @@ -1,8 +0,0 @@ -.styleA { - background: red; -} - -.styleB { - background: blue; -} - diff --git a/test/cases/contenthash-multiple-entries/expected/webpack-5/788f5dc856f2e114b45c.css b/test/cases/contenthash-multiple-entries/expected/webpack-5/788f5dc856f2e114b45c.css deleted file mode 100644 index 95d70a8e..00000000 --- a/test/cases/contenthash-multiple-entries/expected/webpack-5/788f5dc856f2e114b45c.css +++ /dev/null @@ -1,4 +0,0 @@ -.styleA { - background: red; -} - diff --git a/test/cases/contenthash/expected/webpack-5-importModule/1.main.a45a4571ab5cece12cf0.css b/test/cases/contenthash/expected/1.main.a45a4571ab5cece12cf0.css similarity index 100% rename from test/cases/contenthash/expected/webpack-5-importModule/1.main.a45a4571ab5cece12cf0.css rename to test/cases/contenthash/expected/1.main.a45a4571ab5cece12cf0.css diff --git a/test/cases/contenthash/expected/webpack-5-importModule/2.main.c282a646790b09956021.css b/test/cases/contenthash/expected/2.main.c282a646790b09956021.css similarity index 100% rename from test/cases/contenthash/expected/webpack-5-importModule/2.main.c282a646790b09956021.css rename to test/cases/contenthash/expected/2.main.c282a646790b09956021.css diff --git a/test/cases/contenthash/expected/webpack-5/1.main.a45a4571ab5cece12cf0.css b/test/cases/contenthash/expected/webpack-5/1.main.a45a4571ab5cece12cf0.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/contenthash/expected/webpack-5/1.main.a45a4571ab5cece12cf0.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/contenthash/expected/webpack-5/2.main.c282a646790b09956021.css b/test/cases/contenthash/expected/webpack-5/2.main.c282a646790b09956021.css deleted file mode 100644 index ec3b88b5..00000000 --- a/test/cases/contenthash/expected/webpack-5/2.main.c282a646790b09956021.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: green; -} - diff --git a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5-importModule/common.css b/test/cases/dependOn-multiple-files-per-entry/expected/common.css similarity index 100% rename from test/cases/dependOn-multiple-files-per-entry/expected/webpack-5-importModule/common.css rename to test/cases/dependOn-multiple-files-per-entry/expected/common.css diff --git a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5-importModule/common.js b/test/cases/dependOn-multiple-files-per-entry/expected/common.js similarity index 100% rename from test/cases/dependOn-multiple-files-per-entry/expected/webpack-5-importModule/common.js rename to test/cases/dependOn-multiple-files-per-entry/expected/common.js diff --git a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5-importModule/entry1.css b/test/cases/dependOn-multiple-files-per-entry/expected/entry1.css similarity index 100% rename from test/cases/dependOn-multiple-files-per-entry/expected/webpack-5-importModule/entry1.css rename to test/cases/dependOn-multiple-files-per-entry/expected/entry1.css diff --git a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5-importModule/entry1.js b/test/cases/dependOn-multiple-files-per-entry/expected/entry1.js similarity index 100% rename from test/cases/dependOn-multiple-files-per-entry/expected/webpack-5-importModule/entry1.js rename to test/cases/dependOn-multiple-files-per-entry/expected/entry1.js diff --git a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/common.css b/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/common.css deleted file mode 100644 index 7b8c3886..00000000 --- a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/common.css +++ /dev/null @@ -1,8 +0,0 @@ -.styleC { - background: red; -} - -.styleD { - background: blue; -} - diff --git a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/common.js b/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/common.js deleted file mode 100644 index c61498f1..00000000 --- a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/common.js +++ /dev/null @@ -1,171 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ var __webpack_modules__ = ([ -/* 0 */, -/* 1 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }), -/* 2 */, -/* 3 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -/******/ ]); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = __webpack_modules__; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/chunk loaded */ -/******/ (() => { -/******/ var deferred = []; -/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { -/******/ if(chunkIds) { -/******/ priority = priority || 0; -/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; -/******/ deferred[i] = [chunkIds, fn, priority]; -/******/ return; -/******/ } -/******/ var notFulfilled = Infinity; -/******/ for (var i = 0; i < deferred.length; i++) { -/******/ var [chunkIds, fn, priority] = deferred[i]; -/******/ var fulfilled = true; -/******/ for (var j = 0; j < chunkIds.length; j++) { -/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { -/******/ chunkIds.splice(j--, 1); -/******/ } else { -/******/ fulfilled = false; -/******/ if(priority < notFulfilled) notFulfilled = priority; -/******/ } -/******/ } -/******/ if(fulfilled) { -/******/ deferred.splice(i--, 1) -/******/ result = fn(); -/******/ } -/******/ } -/******/ return result; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/jsonp chunk loading */ -/******/ (() => { -/******/ // no baseURI -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ // no chunk on demand loading -/******/ -/******/ // no prefetching -/******/ -/******/ // no preloaded -/******/ -/******/ // no HMR -/******/ -/******/ // no HMR manifest -/******/ -/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); -/******/ -/******/ // install a JSONP callback for chunk loading -/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { -/******/ var [chunkIds, moreModules, runtime] = data; -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0; -/******/ for(moduleId in moreModules) { -/******/ if(__webpack_require__.o(moreModules, moduleId)) { -/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(runtime) var result = runtime(__webpack_require__); -/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { -/******/ installedChunks[chunkId][0](); -/******/ } -/******/ installedChunks[chunkIds[i]] = 0; -/******/ } -/******/ return __webpack_require__.O(result); -/******/ } -/******/ -/******/ var chunkLoadingGlobal = self["webpackChunk"] = self["webpackChunk"] || []; -/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); -/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -// This entry need to be wrapped in an IIFE because it need to be isolated against other entry modules. -(() => { -var __webpack_exports__ = {}; -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _styleC_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1); - - -})(); - -// This entry need to be wrapped in an IIFE because it need to be isolated against other entry modules. -(() => { -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _styleD_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3); - - -})(); - -__webpack_require__.O(); -/******/ })() -; \ No newline at end of file diff --git a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/entry1.css b/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/entry1.css deleted file mode 100644 index bd9b41d3..00000000 --- a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/entry1.css +++ /dev/null @@ -1,8 +0,0 @@ -.styleB { - background: blue; -} - -.styleA { - background: red; -} - diff --git a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/entry1.js b/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/entry1.js deleted file mode 100644 index d31bf3c4..00000000 --- a/test/cases/dependOn-multiple-files-per-entry/expected/webpack-5/entry1.js +++ /dev/null @@ -1,51 +0,0 @@ -(self["webpackChunk"] = self["webpackChunk"] || []).push([[1],[ -/* 0 */, -/* 1 */, -/* 2 */, -/* 3 */, -/* 4 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _styleB_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5); - - - -/***/ }), -/* 5 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }), -/* 6 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _styleA_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7); - - - -/***/ }), -/* 7 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -], -/******/ __webpack_require__ => { // webpackRuntimeModules -/******/ "use strict"; -/******/ -/******/ var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) -/******/ var __webpack_exports__ = (__webpack_exec__(6), __webpack_exec__(4)); -/******/ } -]); \ No newline at end of file diff --git a/test/cases/dependOn/expected/webpack-5-importModule/common.css b/test/cases/dependOn/expected/common.css similarity index 100% rename from test/cases/dependOn/expected/webpack-5-importModule/common.css rename to test/cases/dependOn/expected/common.css diff --git a/test/cases/dependOn/expected/webpack-5-importModule/common.js b/test/cases/dependOn/expected/common.js similarity index 100% rename from test/cases/dependOn/expected/webpack-5-importModule/common.js rename to test/cases/dependOn/expected/common.js diff --git a/test/cases/dependOn/expected/webpack-5-importModule/entry1.css b/test/cases/dependOn/expected/entry1.css similarity index 100% rename from test/cases/dependOn/expected/webpack-5-importModule/entry1.css rename to test/cases/dependOn/expected/entry1.css diff --git a/test/cases/dependOn/expected/webpack-5-importModule/entry1.js b/test/cases/dependOn/expected/entry1.js similarity index 100% rename from test/cases/dependOn/expected/webpack-5-importModule/entry1.js rename to test/cases/dependOn/expected/entry1.js diff --git a/test/cases/dependOn/expected/webpack-5/common.css b/test/cases/dependOn/expected/webpack-5/common.css deleted file mode 100644 index bbb56596..00000000 --- a/test/cases/dependOn/expected/webpack-5/common.css +++ /dev/null @@ -1,4 +0,0 @@ -.styleB { - background: blue; -} - diff --git a/test/cases/dependOn/expected/webpack-5/common.js b/test/cases/dependOn/expected/webpack-5/common.js deleted file mode 100644 index 5abb0200..00000000 --- a/test/cases/dependOn/expected/webpack-5/common.js +++ /dev/null @@ -1,153 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ var __webpack_modules__ = ([ -/* 0 */, -/* 1 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -/******/ ]); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = __webpack_modules__; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/chunk loaded */ -/******/ (() => { -/******/ var deferred = []; -/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { -/******/ if(chunkIds) { -/******/ priority = priority || 0; -/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; -/******/ deferred[i] = [chunkIds, fn, priority]; -/******/ return; -/******/ } -/******/ var notFulfilled = Infinity; -/******/ for (var i = 0; i < deferred.length; i++) { -/******/ var [chunkIds, fn, priority] = deferred[i]; -/******/ var fulfilled = true; -/******/ for (var j = 0; j < chunkIds.length; j++) { -/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { -/******/ chunkIds.splice(j--, 1); -/******/ } else { -/******/ fulfilled = false; -/******/ if(priority < notFulfilled) notFulfilled = priority; -/******/ } -/******/ } -/******/ if(fulfilled) { -/******/ deferred.splice(i--, 1) -/******/ result = fn(); -/******/ } -/******/ } -/******/ return result; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/jsonp chunk loading */ -/******/ (() => { -/******/ // no baseURI -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ // no chunk on demand loading -/******/ -/******/ // no prefetching -/******/ -/******/ // no preloaded -/******/ -/******/ // no HMR -/******/ -/******/ // no HMR manifest -/******/ -/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); -/******/ -/******/ // install a JSONP callback for chunk loading -/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { -/******/ var [chunkIds, moreModules, runtime] = data; -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0; -/******/ for(moduleId in moreModules) { -/******/ if(__webpack_require__.o(moreModules, moduleId)) { -/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(runtime) var result = runtime(__webpack_require__); -/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { -/******/ installedChunks[chunkId][0](); -/******/ } -/******/ installedChunks[chunkIds[i]] = 0; -/******/ } -/******/ return __webpack_require__.O(result); -/******/ } -/******/ -/******/ var chunkLoadingGlobal = self["webpackChunk"] = self["webpackChunk"] || []; -/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); -/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. -(() => { -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _styleB_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1); - - -})(); - -__webpack_require__.O(); -/******/ })() -; \ No newline at end of file diff --git a/test/cases/dependOn/expected/webpack-5/entry1.css b/test/cases/dependOn/expected/webpack-5/entry1.css deleted file mode 100644 index 95d70a8e..00000000 --- a/test/cases/dependOn/expected/webpack-5/entry1.css +++ /dev/null @@ -1,4 +0,0 @@ -.styleA { - background: red; -} - diff --git a/test/cases/dependOn/expected/webpack-5/entry1.js b/test/cases/dependOn/expected/webpack-5/entry1.js deleted file mode 100644 index b66131d3..00000000 --- a/test/cases/dependOn/expected/webpack-5/entry1.js +++ /dev/null @@ -1,30 +0,0 @@ -(self["webpackChunk"] = self["webpackChunk"] || []).push([[1],[ -/* 0 */, -/* 1 */, -/* 2 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _styleA_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3); - - - -/***/ }), -/* 3 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -], -/******/ __webpack_require__ => { // webpackRuntimeModules -/******/ "use strict"; -/******/ -/******/ var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) -/******/ var __webpack_exports__ = (__webpack_exec__(2)); -/******/ } -]); \ No newline at end of file diff --git a/test/cases/devtool-source-map-from-loaders/expected/webpack-5-importModule/main.css b/test/cases/devtool-source-map-from-loaders/expected/main.css similarity index 100% rename from test/cases/devtool-source-map-from-loaders/expected/webpack-5-importModule/main.css rename to test/cases/devtool-source-map-from-loaders/expected/main.css diff --git a/test/cases/devtool-source-map-from-loaders/expected/webpack-5-importModule/main.css.map b/test/cases/devtool-source-map-from-loaders/expected/main.css.map similarity index 100% rename from test/cases/devtool-source-map-from-loaders/expected/webpack-5-importModule/main.css.map rename to test/cases/devtool-source-map-from-loaders/expected/main.css.map diff --git a/test/cases/devtool-source-map-from-loaders/expected/webpack-5/main.css b/test/cases/devtool-source-map-from-loaders/expected/webpack-5/main.css deleted file mode 100644 index 8f8cf968..00000000 --- a/test/cases/devtool-source-map-from-loaders/expected/webpack-5/main.css +++ /dev/null @@ -1,6 +0,0 @@ -body { - background: red; -} - - -/*# sourceMappingURL=main.css.map*/ \ No newline at end of file diff --git a/test/cases/devtool-source-map-from-loaders/expected/webpack-5/main.css.map b/test/cases/devtool-source-map-from-loaders/expected/webpack-5/main.css.map deleted file mode 100644 index bb767168..00000000 --- a/test/cases/devtool-source-map-from-loaders/expected/webpack-5/main.css.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["webpack:///./style.css"],"names":[],"mappings":"AAAA;EACE,eAAe;AACjB","file":"main.css","sourcesContent":["body {\n background: red;\n}\n"],"sourceRoot":""} \ No newline at end of file diff --git a/test/cases/chunkFilename/expected/webpack-5-importModule/main.css b/test/cases/devtool-source-map-no-source-maps-from-loaders/expected/main.css similarity index 100% rename from test/cases/chunkFilename/expected/webpack-5-importModule/main.css rename to test/cases/devtool-source-map-no-source-maps-from-loaders/expected/main.css diff --git a/test/cases/es-module-concatenation-modules/expected/webpack-5-importModule/main.css b/test/cases/es-module-concatenation-modules/expected/main.css similarity index 100% rename from test/cases/es-module-concatenation-modules/expected/webpack-5-importModule/main.css rename to test/cases/es-module-concatenation-modules/expected/main.css diff --git a/test/cases/es-module-concatenation-modules/expected/webpack-5-importModule/main.js b/test/cases/es-module-concatenation-modules/expected/main.js similarity index 100% rename from test/cases/es-module-concatenation-modules/expected/webpack-5-importModule/main.js rename to test/cases/es-module-concatenation-modules/expected/main.js diff --git a/test/cases/es-module-concatenation-modules/expected/webpack-5/main.css b/test/cases/es-module-concatenation-modules/expected/webpack-5/main.css deleted file mode 100644 index 414d12e5..00000000 --- a/test/cases/es-module-concatenation-modules/expected/webpack-5/main.css +++ /dev/null @@ -1,12 +0,0 @@ -.foo__a { - background: red; -} - -.foo__b { - background: green; -} - -.foo__c { - background: blue; -} - diff --git a/test/cases/es-module-concatenation-modules/expected/webpack-5/main.js b/test/cases/es-module-concatenation-modules/expected/webpack-5/main.js deleted file mode 100644 index d289c825..00000000 --- a/test/cases/es-module-concatenation-modules/expected/webpack-5/main.js +++ /dev/null @@ -1,93 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ // The require scope -/******/ var __webpack_require__ = {}; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/define property getters */ -/******/ (() => { -/******/ // define getter functions for harmony exports -/******/ __webpack_require__.d = (exports, definition) => { -/******/ for(var key in definition) { -/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { -/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); -/******/ } -/******/ } -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -// ESM COMPAT FLAG -__webpack_require__.r(__webpack_exports__); - -// EXPORTS -__webpack_require__.d(__webpack_exports__, { - "a": () => (/* reexport */ a_namespaceObject), - "b": () => (/* reexport */ b_namespaceObject), - "c": () => (/* reexport */ c) -}); - -// NAMESPACE OBJECT: ./a.css -var a_namespaceObject = {}; -__webpack_require__.r(a_namespaceObject); -__webpack_require__.d(a_namespaceObject, { - "a": () => (a) -}); - -// NAMESPACE OBJECT: ./b.css -var b_namespaceObject = {}; -__webpack_require__.r(b_namespaceObject); -__webpack_require__.d(b_namespaceObject, { - "b": () => (b) -}); - -// NAMESPACE OBJECT: ./index.js -var index_namespaceObject = {}; -__webpack_require__.r(index_namespaceObject); -__webpack_require__.d(index_namespaceObject, { - "a": () => (a_namespaceObject), - "b": () => (b_namespaceObject), - "c": () => (c) -}); - -;// CONCATENATED MODULE: ./a.css -// extracted by mini-css-extract-plugin -var a = "foo__a"; -;// CONCATENATED MODULE: ./b.css -// extracted by mini-css-extract-plugin -var b = "foo__b"; -;// CONCATENATED MODULE: ./c.css -// extracted by mini-css-extract-plugin -var c = "foo__c"; -;// CONCATENATED MODULE: ./index.js -/* eslint-disable import/no-namespace */ - - - - - - - - -// eslint-disable-next-line no-console -console.log(index_namespaceObject); - -/******/ })() -; \ No newline at end of file diff --git a/test/cases/es-module-concatenation/expected/webpack-5-importModule/main.css b/test/cases/es-module-concatenation/expected/main.css similarity index 100% rename from test/cases/es-module-concatenation/expected/webpack-5-importModule/main.css rename to test/cases/es-module-concatenation/expected/main.css diff --git a/test/cases/es-module-concatenation/expected/webpack-5-importModule/main.js b/test/cases/es-module-concatenation/expected/main.js similarity index 100% rename from test/cases/es-module-concatenation/expected/webpack-5-importModule/main.js rename to test/cases/es-module-concatenation/expected/main.js diff --git a/test/cases/es-module-concatenation/expected/webpack-5/main.css b/test/cases/es-module-concatenation/expected/webpack-5/main.css deleted file mode 100644 index a5728976..00000000 --- a/test/cases/es-module-concatenation/expected/webpack-5/main.css +++ /dev/null @@ -1,12 +0,0 @@ -.a { - background: red; -} - -.b { - background: green; -} - -.c { - background: blue; -} - diff --git a/test/cases/es-module-concatenation/expected/webpack-5/main.js b/test/cases/es-module-concatenation/expected/webpack-5/main.js deleted file mode 100644 index 394a6125..00000000 --- a/test/cases/es-module-concatenation/expected/webpack-5/main.js +++ /dev/null @@ -1,38 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ // The require scope -/******/ var __webpack_require__ = {}; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -// ESM COMPAT FLAG -__webpack_require__.r(__webpack_exports__); - -;// CONCATENATED MODULE: ./a.css -// extracted by mini-css-extract-plugin - -;// CONCATENATED MODULE: ./b.css -// extracted by mini-css-extract-plugin - -;// CONCATENATED MODULE: ./c.css -// extracted by mini-css-extract-plugin - -;// CONCATENATED MODULE: ./index.js - - - - -/******/ })() -; \ No newline at end of file diff --git a/test/cases/es-named-export/expected/webpack-5-importModule/main.css b/test/cases/es-named-export/expected/main.css similarity index 100% rename from test/cases/es-named-export/expected/webpack-5-importModule/main.css rename to test/cases/es-named-export/expected/main.css diff --git a/test/cases/es-named-export/expected/webpack-5-importModule/main.js b/test/cases/es-named-export/expected/main.js similarity index 100% rename from test/cases/es-named-export/expected/webpack-5-importModule/main.js rename to test/cases/es-named-export/expected/main.js diff --git a/test/cases/es-named-export/expected/webpack-5/main.css b/test/cases/es-named-export/expected/webpack-5/main.css deleted file mode 100644 index aa9b1569..00000000 --- a/test/cases/es-named-export/expected/webpack-5/main.css +++ /dev/null @@ -1,12 +0,0 @@ -.foo__style__a-class { - background: red; -} - -.foo__style__b__class { - color: green; -} - -.foo__style__cClass { - color: blue; -} - diff --git a/test/cases/es-named-export/expected/webpack-5/main.js b/test/cases/es-named-export/expected/webpack-5/main.js deleted file mode 100644 index 8cf22c2c..00000000 --- a/test/cases/es-named-export/expected/webpack-5/main.js +++ /dev/null @@ -1,89 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ var __webpack_modules__ = ([ -/* 0 */, -/* 1 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "aClass": () => (/* binding */ aClass), -/* harmony export */ "bClass": () => (/* binding */ bClass), -/* harmony export */ "cClass": () => (/* binding */ cClass) -/* harmony export */ }); -// extracted by mini-css-extract-plugin -var aClass = "foo__style__a-class"; -var bClass = "foo__style__b__class"; -var cClass = "foo__style__cClass"; - -/***/ }) -/******/ ]); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/define property getters */ -/******/ (() => { -/******/ // define getter functions for harmony exports -/******/ __webpack_require__.d = (exports, definition) => { -/******/ for(var key in definition) { -/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { -/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); -/******/ } -/******/ } -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. -(() => { -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _style_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1); - - -// eslint-disable-next-line no-console -console.log({ css: _style_css__WEBPACK_IMPORTED_MODULE_0__.default, aClass: _style_css__WEBPACK_IMPORTED_MODULE_0__.aClass, bClass: _style_css__WEBPACK_IMPORTED_MODULE_0__.bClass, cClass: _style_css__WEBPACK_IMPORTED_MODULE_0__.cClass }); - -})(); - -/******/ })() -; \ No newline at end of file diff --git a/test/cases/filename-without-template/expected/webpack-5-importModule/0.main.css b/test/cases/filename-without-template/expected/0.main.css similarity index 100% rename from test/cases/filename-without-template/expected/webpack-5-importModule/0.main.css rename to test/cases/filename-without-template/expected/0.main.css diff --git a/test/cases/chunkFilename/expected/webpack-5/main.css b/test/cases/filename-without-template/expected/main.css similarity index 100% rename from test/cases/chunkFilename/expected/webpack-5/main.css rename to test/cases/filename-without-template/expected/main.css diff --git a/test/cases/filename-without-template/expected/webpack-5-importModule/main.css b/test/cases/filename-without-template/expected/webpack-5-importModule/main.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/filename-without-template/expected/webpack-5-importModule/main.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/filename-without-template/expected/webpack-5/0.main.css b/test/cases/filename-without-template/expected/webpack-5/0.main.css deleted file mode 100644 index e665100a..00000000 --- a/test/cases/filename-without-template/expected/webpack-5/0.main.css +++ /dev/null @@ -1,4 +0,0 @@ -.async { - color: red; -} - diff --git a/test/cases/filename-without-template/expected/webpack-5/main.css b/test/cases/filename-without-template/expected/webpack-5/main.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/filename-without-template/expected/webpack-5/main.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/hmr/expected/webpack-5-importModule/main.css b/test/cases/hmr/expected/main.css similarity index 100% rename from test/cases/hmr/expected/webpack-5-importModule/main.css rename to test/cases/hmr/expected/main.css diff --git a/test/cases/hmr/expected/webpack-5-importModule/main.js b/test/cases/hmr/expected/main.js similarity index 100% rename from test/cases/hmr/expected/webpack-5-importModule/main.js rename to test/cases/hmr/expected/main.js diff --git a/test/cases/hmr/expected/webpack-5/main.css b/test/cases/hmr/expected/webpack-5/main.css deleted file mode 100644 index 6f77cc07..00000000 --- a/test/cases/hmr/expected/webpack-5/main.css +++ /dev/null @@ -1,24 +0,0 @@ -@import url(https://some/other/external/css); -@import url(https://some/external/css); -body { - background: red; -} - -.c { - background: red; -} - -.c { - color: yellow; -} - -.b { - background: red; -} - -.b { - color: yellow; -} - - - diff --git a/test/cases/hmr/expected/webpack-5/main.js b/test/cases/hmr/expected/webpack-5/main.js deleted file mode 100644 index 6db73b01..00000000 --- a/test/cases/hmr/expected/webpack-5/main.js +++ /dev/null @@ -1,1454 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ var __webpack_modules__ = ([ -/* 0 */ -/***/ ((module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - if(true) { - // - var cssReload = __webpack_require__(1)(module.id, {"locals":false}); - module.hot.dispose(cssReload); - module.hot.accept(undefined, cssReload); - } - - -/***/ }), -/* 1 */ -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { - -/* eslint-env browser */ -/* - eslint-disable - no-console, - func-names -*/ - -const normalizeUrl = __webpack_require__(2); - -const srcByModuleId = Object.create(null); - -const noDocument = typeof document === "undefined"; - -const { forEach } = Array.prototype; - -function debounce(fn, time) { - let timeout = 0; - - return function () { - const self = this; - // eslint-disable-next-line prefer-rest-params - const args = arguments; - - const functionCall = function functionCall() { - return fn.apply(self, args); - }; - - clearTimeout(timeout); - timeout = setTimeout(functionCall, time); - }; -} - -function noop() {} - -function getCurrentScriptUrl(moduleId) { - let src = srcByModuleId[moduleId]; - - if (!src) { - if (document.currentScript) { - ({ src } = document.currentScript); - } else { - const scripts = document.getElementsByTagName("script"); - const lastScriptTag = scripts[scripts.length - 1]; - - if (lastScriptTag) { - ({ src } = lastScriptTag); - } - } - - srcByModuleId[moduleId] = src; - } - - return function (fileMap) { - if (!src) { - return null; - } - - const splitResult = src.split(/([^\\/]+)\.js$/); - const filename = splitResult && splitResult[1]; - - if (!filename) { - return [src.replace(".js", ".css")]; - } - - if (!fileMap) { - return [src.replace(".js", ".css")]; - } - - return fileMap.split(",").map((mapRule) => { - const reg = new RegExp(`${filename}\\.js$`, "g"); - - return normalizeUrl( - src.replace(reg, `${mapRule.replace(/{fileName}/g, filename)}.css`) - ); - }); - }; -} - -function updateCss(el, url) { - if (!url) { - if (!el.href) { - return; - } - - // eslint-disable-next-line - url = el.href.split("?")[0]; - } - - if (!isUrlRequest(url)) { - return; - } - - if (el.isLoaded === false) { - // We seem to be about to replace a css link that hasn't loaded yet. - // We're probably changing the same file more than once. - return; - } - - if (!url || !(url.indexOf(".css") > -1)) { - return; - } - - // eslint-disable-next-line no-param-reassign - el.visited = true; - - const newEl = el.cloneNode(); - - newEl.isLoaded = false; - - newEl.addEventListener("load", () => { - if (newEl.isLoaded) { - return; - } - - newEl.isLoaded = true; - el.parentNode.removeChild(el); - }); - - newEl.addEventListener("error", () => { - if (newEl.isLoaded) { - return; - } - - newEl.isLoaded = true; - el.parentNode.removeChild(el); - }); - - newEl.href = `${url}?${Date.now()}`; - - if (el.nextSibling) { - el.parentNode.insertBefore(newEl, el.nextSibling); - } else { - el.parentNode.appendChild(newEl); - } -} - -function getReloadUrl(href, src) { - let ret; - - // eslint-disable-next-line no-param-reassign - href = normalizeUrl(href, { stripWWW: false }); - - // eslint-disable-next-line array-callback-return - src.some((url) => { - if (href.indexOf(src) > -1) { - ret = url; - } - }); - - return ret; -} - -function reloadStyle(src) { - if (!src) { - return false; - } - - const elements = document.querySelectorAll("link"); - let loaded = false; - - forEach.call(elements, (el) => { - if (!el.href) { - return; - } - - const url = getReloadUrl(el.href, src); - - if (!isUrlRequest(url)) { - return; - } - - if (el.visited === true) { - return; - } - - if (url) { - updateCss(el, url); - - loaded = true; - } - }); - - return loaded; -} - -function reloadAll() { - const elements = document.querySelectorAll("link"); - - forEach.call(elements, (el) => { - if (el.visited === true) { - return; - } - - updateCss(el); - }); -} - -function isUrlRequest(url) { - // An URL is not an request if - - // It is not http or https - if (!/^https?:/i.test(url)) { - return false; - } - - return true; -} - -module.exports = function (moduleId, options) { - if (noDocument) { - console.log("no window.document found, will not HMR CSS"); - - return noop; - } - - const getScriptSrc = getCurrentScriptUrl(moduleId); - - function update() { - const src = getScriptSrc(options.filename); - const reloaded = reloadStyle(src); - - if (options.locals) { - console.log("[HMR] Detected local css modules. Reload all css"); - - reloadAll(); - - return; - } - - if (reloaded) { - console.log("[HMR] css reload %s", src.join(" ")); - } else { - console.log("[HMR] Reload all css"); - - reloadAll(); - } - } - - return debounce(update, 50); -}; - - -/***/ }), -/* 2 */ -/***/ ((module) => { - -/* eslint-disable */ - -function normalizeUrl(pathComponents) { - return pathComponents - .reduce(function (accumulator, item) { - switch (item) { - case "..": - accumulator.pop(); - break; - case ".": - break; - default: - accumulator.push(item); - } - - return accumulator; - }, []) - .join("/"); -} - -module.exports = function (urlString) { - urlString = urlString.trim(); - - if (/^data:/i.test(urlString)) { - return urlString; - } - - var protocol = - urlString.indexOf("//") !== -1 ? urlString.split("//")[0] + "//" : ""; - var components = urlString.replace(new RegExp(protocol, "i"), "").split("/"); - var host = components[0].toLowerCase().replace(/\.$/, ""); - - components[0] = ""; - - var path = normalizeUrl(components); - - return protocol + host + path; -}; - - -/***/ }) -/******/ ]); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ if (cachedModule.error !== undefined) throw cachedModule.error; -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ id: moduleId, -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ try { -/******/ var execOptions = { id: moduleId, module: module, factory: __webpack_modules__[moduleId], require: __webpack_require__ }; -/******/ __webpack_require__.i.forEach(function(handler) { handler(execOptions); }); -/******/ module = execOptions.module; -/******/ execOptions.factory.call(module.exports, module, module.exports, execOptions.require); -/******/ } catch(e) { -/******/ module.error = e; -/******/ throw e; -/******/ } -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = __webpack_modules__; -/******/ -/******/ // expose the module cache -/******/ __webpack_require__.c = __webpack_module_cache__; -/******/ -/******/ // expose the module execution interceptor -/******/ __webpack_require__.i = []; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/get javascript update chunk filename */ -/******/ (() => { -/******/ // This function allow to reference all chunks -/******/ __webpack_require__.hu = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + chunkId + "." + __webpack_require__.h() + ".hot-update.js"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get mini-css chunk filename */ -/******/ (() => { -/******/ // This function allow to reference all chunks -/******/ __webpack_require__.miniCssF = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return undefined; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get update manifest filename */ -/******/ (() => { -/******/ __webpack_require__.hmrF = () => ("main." + __webpack_require__.h() + ".hot-update.json"); -/******/ })(); -/******/ -/******/ /* webpack/runtime/getFullHash */ -/******/ (() => { -/******/ __webpack_require__.h = () => ("xxxxxxxxxxxxxxxxxxxxxx") -/******/ })(); -/******/ -/******/ /* webpack/runtime/global */ -/******/ (() => { -/******/ __webpack_require__.g = (function() { -/******/ if (typeof globalThis === 'object') return globalThis; -/******/ try { -/******/ return this || new Function('return this')(); -/******/ } catch (e) { -/******/ if (typeof window === 'object') return window; -/******/ } -/******/ })(); -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/load script */ -/******/ (() => { -/******/ var inProgress = {}; -/******/ // data-webpack is not used as build has no uniqueName -/******/ // loadScript function to load a script via script tag -/******/ __webpack_require__.l = (url, done, key, chunkId) => { -/******/ if(inProgress[url]) { inProgress[url].push(done); return; } -/******/ var script, needAttach; -/******/ if(key !== undefined) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ for(var i = 0; i < scripts.length; i++) { -/******/ var s = scripts[i]; -/******/ if(s.getAttribute("src") == url) { script = s; break; } -/******/ } -/******/ } -/******/ if(!script) { -/******/ needAttach = true; -/******/ script = document.createElement('script'); -/******/ -/******/ script.charset = 'utf-8'; -/******/ script.timeout = 120; -/******/ if (__webpack_require__.nc) { -/******/ script.setAttribute("nonce", __webpack_require__.nc); -/******/ } -/******/ -/******/ script.src = url; -/******/ } -/******/ inProgress[url] = [done]; -/******/ var onScriptComplete = (prev, event) => { -/******/ // avoid mem leaks in IE. -/******/ script.onerror = script.onload = null; -/******/ clearTimeout(timeout); -/******/ var doneFns = inProgress[url]; -/******/ delete inProgress[url]; -/******/ script.parentNode && script.parentNode.removeChild(script); -/******/ doneFns && doneFns.forEach((fn) => (fn(event))); -/******/ if(prev) return prev(event); -/******/ } -/******/ ; -/******/ var timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000); -/******/ script.onerror = onScriptComplete.bind(null, script.onerror); -/******/ script.onload = onScriptComplete.bind(null, script.onload); -/******/ needAttach && document.head.appendChild(script); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/hot module replacement */ -/******/ (() => { -/******/ var currentModuleData = {}; -/******/ var installedModules = __webpack_require__.c; -/******/ -/******/ // module and require creation -/******/ var currentChildModule; -/******/ var currentParents = []; -/******/ -/******/ // status -/******/ var registeredStatusHandlers = []; -/******/ var currentStatus = "idle"; -/******/ -/******/ // while downloading -/******/ var blockingPromises; -/******/ -/******/ // The update info -/******/ var currentUpdateApplyHandlers; -/******/ var queuedInvalidatedModules; -/******/ -/******/ // eslint-disable-next-line no-unused-vars -/******/ __webpack_require__.hmrD = currentModuleData; -/******/ -/******/ __webpack_require__.i.push(function (options) { -/******/ var module = options.module; -/******/ var require = createRequire(options.require, options.id); -/******/ module.hot = createModuleHotObject(options.id, module); -/******/ module.parents = currentParents; -/******/ module.children = []; -/******/ currentParents = []; -/******/ options.require = require; -/******/ }); -/******/ -/******/ __webpack_require__.hmrC = {}; -/******/ __webpack_require__.hmrI = {}; -/******/ -/******/ function createRequire(require, moduleId) { -/******/ var me = installedModules[moduleId]; -/******/ if (!me) return require; -/******/ var fn = function (request) { -/******/ if (me.hot.active) { -/******/ if (installedModules[request]) { -/******/ var parents = installedModules[request].parents; -/******/ if (parents.indexOf(moduleId) === -1) { -/******/ parents.push(moduleId); -/******/ } -/******/ } else { -/******/ currentParents = [moduleId]; -/******/ currentChildModule = request; -/******/ } -/******/ if (me.children.indexOf(request) === -1) { -/******/ me.children.push(request); -/******/ } -/******/ } else { -/******/ console.warn( -/******/ "[HMR] unexpected require(" + -/******/ request + -/******/ ") from disposed module " + -/******/ moduleId -/******/ ); -/******/ currentParents = []; -/******/ } -/******/ return require(request); -/******/ }; -/******/ var createPropertyDescriptor = function (name) { -/******/ return { -/******/ configurable: true, -/******/ enumerable: true, -/******/ get: function () { -/******/ return require[name]; -/******/ }, -/******/ set: function (value) { -/******/ require[name] = value; -/******/ } -/******/ }; -/******/ }; -/******/ for (var name in require) { -/******/ if (Object.prototype.hasOwnProperty.call(require, name) && name !== "e") { -/******/ Object.defineProperty(fn, name, createPropertyDescriptor(name)); -/******/ } -/******/ } -/******/ fn.e = function (chunkId) { -/******/ return trackBlockingPromise(require.e(chunkId)); -/******/ }; -/******/ return fn; -/******/ } -/******/ -/******/ function createModuleHotObject(moduleId, me) { -/******/ var _main = currentChildModule !== moduleId; -/******/ var hot = { -/******/ // private stuff -/******/ _acceptedDependencies: {}, -/******/ _acceptedErrorHandlers: {}, -/******/ _declinedDependencies: {}, -/******/ _selfAccepted: false, -/******/ _selfDeclined: false, -/******/ _selfInvalidated: false, -/******/ _disposeHandlers: [], -/******/ _main: _main, -/******/ _requireSelf: function () { -/******/ currentParents = me.parents.slice(); -/******/ currentChildModule = _main ? undefined : moduleId; -/******/ __webpack_require__(moduleId); -/******/ }, -/******/ -/******/ // Module API -/******/ active: true, -/******/ accept: function (dep, callback, errorHandler) { -/******/ if (dep === undefined) hot._selfAccepted = true; -/******/ else if (typeof dep === "function") hot._selfAccepted = dep; -/******/ else if (typeof dep === "object" && dep !== null) { -/******/ for (var i = 0; i < dep.length; i++) { -/******/ hot._acceptedDependencies[dep[i]] = callback || function () {}; -/******/ hot._acceptedErrorHandlers[dep[i]] = errorHandler; -/******/ } -/******/ } else { -/******/ hot._acceptedDependencies[dep] = callback || function () {}; -/******/ hot._acceptedErrorHandlers[dep] = errorHandler; -/******/ } -/******/ }, -/******/ decline: function (dep) { -/******/ if (dep === undefined) hot._selfDeclined = true; -/******/ else if (typeof dep === "object" && dep !== null) -/******/ for (var i = 0; i < dep.length; i++) -/******/ hot._declinedDependencies[dep[i]] = true; -/******/ else hot._declinedDependencies[dep] = true; -/******/ }, -/******/ dispose: function (callback) { -/******/ hot._disposeHandlers.push(callback); -/******/ }, -/******/ addDisposeHandler: function (callback) { -/******/ hot._disposeHandlers.push(callback); -/******/ }, -/******/ removeDisposeHandler: function (callback) { -/******/ var idx = hot._disposeHandlers.indexOf(callback); -/******/ if (idx >= 0) hot._disposeHandlers.splice(idx, 1); -/******/ }, -/******/ invalidate: function () { -/******/ this._selfInvalidated = true; -/******/ switch (currentStatus) { -/******/ case "idle": -/******/ currentUpdateApplyHandlers = []; -/******/ Object.keys(__webpack_require__.hmrI).forEach(function (key) { -/******/ __webpack_require__.hmrI[key]( -/******/ moduleId, -/******/ currentUpdateApplyHandlers -/******/ ); -/******/ }); -/******/ setStatus("ready"); -/******/ break; -/******/ case "ready": -/******/ Object.keys(__webpack_require__.hmrI).forEach(function (key) { -/******/ __webpack_require__.hmrI[key]( -/******/ moduleId, -/******/ currentUpdateApplyHandlers -/******/ ); -/******/ }); -/******/ break; -/******/ case "prepare": -/******/ case "check": -/******/ case "dispose": -/******/ case "apply": -/******/ (queuedInvalidatedModules = queuedInvalidatedModules || []).push( -/******/ moduleId -/******/ ); -/******/ break; -/******/ default: -/******/ // ignore requests in error states -/******/ break; -/******/ } -/******/ }, -/******/ -/******/ // Management API -/******/ check: hotCheck, -/******/ apply: hotApply, -/******/ status: function (l) { -/******/ if (!l) return currentStatus; -/******/ registeredStatusHandlers.push(l); -/******/ }, -/******/ addStatusHandler: function (l) { -/******/ registeredStatusHandlers.push(l); -/******/ }, -/******/ removeStatusHandler: function (l) { -/******/ var idx = registeredStatusHandlers.indexOf(l); -/******/ if (idx >= 0) registeredStatusHandlers.splice(idx, 1); -/******/ }, -/******/ -/******/ //inherit from previous dispose call -/******/ data: currentModuleData[moduleId] -/******/ }; -/******/ currentChildModule = undefined; -/******/ return hot; -/******/ } -/******/ -/******/ function setStatus(newStatus) { -/******/ currentStatus = newStatus; -/******/ for (var i = 0; i < registeredStatusHandlers.length; i++) -/******/ registeredStatusHandlers[i].call(null, newStatus); -/******/ } -/******/ -/******/ function trackBlockingPromise(promise) { -/******/ switch (currentStatus) { -/******/ case "ready": -/******/ setStatus("prepare"); -/******/ blockingPromises.push(promise); -/******/ waitForBlockingPromises(function () { -/******/ setStatus("ready"); -/******/ }); -/******/ return promise; -/******/ case "prepare": -/******/ blockingPromises.push(promise); -/******/ return promise; -/******/ default: -/******/ return promise; -/******/ } -/******/ } -/******/ -/******/ function waitForBlockingPromises(fn) { -/******/ if (blockingPromises.length === 0) return fn(); -/******/ var blocker = blockingPromises; -/******/ blockingPromises = []; -/******/ return Promise.all(blocker).then(function () { -/******/ return waitForBlockingPromises(fn); -/******/ }); -/******/ } -/******/ -/******/ function hotCheck(applyOnUpdate) { -/******/ if (currentStatus !== "idle") { -/******/ throw new Error("check() is only allowed in idle status"); -/******/ } -/******/ setStatus("check"); -/******/ return __webpack_require__.hmrM().then(function (update) { -/******/ if (!update) { -/******/ setStatus(applyInvalidatedModules() ? "ready" : "idle"); -/******/ return null; -/******/ } -/******/ -/******/ setStatus("prepare"); -/******/ -/******/ var updatedModules = []; -/******/ blockingPromises = []; -/******/ currentUpdateApplyHandlers = []; -/******/ -/******/ return Promise.all( -/******/ Object.keys(__webpack_require__.hmrC).reduce(function ( -/******/ promises, -/******/ key -/******/ ) { -/******/ __webpack_require__.hmrC[key]( -/******/ update.c, -/******/ update.r, -/******/ update.m, -/******/ promises, -/******/ currentUpdateApplyHandlers, -/******/ updatedModules -/******/ ); -/******/ return promises; -/******/ }, -/******/ []) -/******/ ).then(function () { -/******/ return waitForBlockingPromises(function () { -/******/ if (applyOnUpdate) { -/******/ return internalApply(applyOnUpdate); -/******/ } else { -/******/ setStatus("ready"); -/******/ -/******/ return updatedModules; -/******/ } -/******/ }); -/******/ }); -/******/ }); -/******/ } -/******/ -/******/ function hotApply(options) { -/******/ if (currentStatus !== "ready") { -/******/ return Promise.resolve().then(function () { -/******/ throw new Error("apply() is only allowed in ready status"); -/******/ }); -/******/ } -/******/ return internalApply(options); -/******/ } -/******/ -/******/ function internalApply(options) { -/******/ options = options || {}; -/******/ -/******/ applyInvalidatedModules(); -/******/ -/******/ var results = currentUpdateApplyHandlers.map(function (handler) { -/******/ return handler(options); -/******/ }); -/******/ currentUpdateApplyHandlers = undefined; -/******/ -/******/ var errors = results -/******/ .map(function (r) { -/******/ return r.error; -/******/ }) -/******/ .filter(Boolean); -/******/ -/******/ if (errors.length > 0) { -/******/ setStatus("abort"); -/******/ return Promise.resolve().then(function () { -/******/ throw errors[0]; -/******/ }); -/******/ } -/******/ -/******/ // Now in "dispose" phase -/******/ setStatus("dispose"); -/******/ -/******/ results.forEach(function (result) { -/******/ if (result.dispose) result.dispose(); -/******/ }); -/******/ -/******/ // Now in "apply" phase -/******/ setStatus("apply"); -/******/ -/******/ var error; -/******/ var reportError = function (err) { -/******/ if (!error) error = err; -/******/ }; -/******/ -/******/ var outdatedModules = []; -/******/ results.forEach(function (result) { -/******/ if (result.apply) { -/******/ var modules = result.apply(reportError); -/******/ if (modules) { -/******/ for (var i = 0; i < modules.length; i++) { -/******/ outdatedModules.push(modules[i]); -/******/ } -/******/ } -/******/ } -/******/ }); -/******/ -/******/ // handle errors in accept handlers and self accepted module load -/******/ if (error) { -/******/ setStatus("fail"); -/******/ return Promise.resolve().then(function () { -/******/ throw error; -/******/ }); -/******/ } -/******/ -/******/ if (queuedInvalidatedModules) { -/******/ return internalApply(options).then(function (list) { -/******/ outdatedModules.forEach(function (moduleId) { -/******/ if (list.indexOf(moduleId) < 0) list.push(moduleId); -/******/ }); -/******/ return list; -/******/ }); -/******/ } -/******/ -/******/ setStatus("idle"); -/******/ return Promise.resolve(outdatedModules); -/******/ } -/******/ -/******/ function applyInvalidatedModules() { -/******/ if (queuedInvalidatedModules) { -/******/ if (!currentUpdateApplyHandlers) currentUpdateApplyHandlers = []; -/******/ Object.keys(__webpack_require__.hmrI).forEach(function (key) { -/******/ queuedInvalidatedModules.forEach(function (moduleId) { -/******/ __webpack_require__.hmrI[key]( -/******/ moduleId, -/******/ currentUpdateApplyHandlers -/******/ ); -/******/ }); -/******/ }); -/******/ queuedInvalidatedModules = undefined; -/******/ return true; -/******/ } -/******/ } -/******/ })(); -/******/ -/******/ /* webpack/runtime/publicPath */ -/******/ (() => { -/******/ var scriptUrl; -/******/ if (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + ""; -/******/ var document = __webpack_require__.g.document; -/******/ if (!scriptUrl && document) { -/******/ if (document.currentScript) -/******/ scriptUrl = document.currentScript.src -/******/ if (!scriptUrl) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ if(scripts.length) scriptUrl = scripts[scripts.length - 1].src -/******/ } -/******/ } -/******/ // When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration -/******/ // or pass an empty string ("") and set the __webpack_public_path__ variable from your code to use your own logic. -/******/ if (!scriptUrl) throw new Error("Automatic publicPath is not supported in this browser"); -/******/ scriptUrl = scriptUrl.replace(/#.*$/, "").replace(/\?.*$/, "").replace(/\/[^\/]+$/, "/"); -/******/ __webpack_require__.p = scriptUrl; -/******/ })(); -/******/ -/******/ /* webpack/runtime/css loading */ -/******/ (() => { -/******/ var createStylesheet = (chunkId, fullhref, resolve, reject) => { -/******/ var linkTag = document.createElement("link"); -/******/ -/******/ linkTag.rel = "stylesheet"; -/******/ linkTag.type = "text/css"; -/******/ var onLinkComplete = (event) => { -/******/ // avoid mem leaks. -/******/ linkTag.onerror = linkTag.onload = null; -/******/ if (event.type === 'load') { -/******/ resolve(); -/******/ } else { -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realHref = event && event.target && event.target.href || fullhref; -/******/ var err = new Error("Loading CSS chunk " + chunkId + " failed.\n(" + realHref + ")"); -/******/ err.code = "CSS_CHUNK_LOAD_FAILED"; -/******/ err.type = errorType; -/******/ err.request = realHref; -/******/ linkTag.parentNode.removeChild(linkTag) -/******/ reject(err); -/******/ } -/******/ } -/******/ linkTag.onerror = linkTag.onload = onLinkComplete; -/******/ linkTag.href = fullhref; -/******/ -/******/ document.head.appendChild(linkTag); -/******/ return linkTag; -/******/ }; -/******/ var findStylesheet = (href, fullhref) => { -/******/ var existingLinkTags = document.getElementsByTagName("link"); -/******/ for(var i = 0; i < existingLinkTags.length; i++) { -/******/ var tag = existingLinkTags[i]; -/******/ var dataHref = tag.getAttribute("data-href") || tag.getAttribute("href"); -/******/ if(tag.rel === "stylesheet" && (dataHref === href || dataHref === fullhref)) return tag; -/******/ } -/******/ var existingStyleTags = document.getElementsByTagName("style"); -/******/ for(var i = 0; i < existingStyleTags.length; i++) { -/******/ var tag = existingStyleTags[i]; -/******/ var dataHref = tag.getAttribute("data-href"); -/******/ if(dataHref === href || dataHref === fullhref) return tag; -/******/ } -/******/ }; -/******/ var loadStylesheet = (chunkId) => { -/******/ return new Promise((resolve, reject) => { -/******/ var href = __webpack_require__.miniCssF(chunkId); -/******/ var fullhref = __webpack_require__.p + href; -/******/ if(findStylesheet(href, fullhref)) return resolve(); -/******/ createStylesheet(chunkId, fullhref, resolve, reject); -/******/ }); -/******/ } -/******/ // no chunk loading -/******/ -/******/ var oldTags = []; -/******/ var newTags = []; -/******/ var applyHandler = (options) => { -/******/ return { dispose: () => { -/******/ for(var i = 0; i < oldTags.length; i++) { -/******/ var oldTag = oldTags[i]; -/******/ if(oldTag.parentNode) oldTag.parentNode.removeChild(oldTag); -/******/ } -/******/ oldTags.length = 0; -/******/ }, apply: () => { -/******/ for(var i = 0; i < newTags.length; i++) newTags[i].rel = "stylesheet"; -/******/ newTags.length = 0; -/******/ } }; -/******/ } -/******/ __webpack_require__.hmrC.miniCss = (chunkIds, removedChunks, removedModules, promises, applyHandlers, updatedModulesList) => { -/******/ applyHandlers.push(applyHandler); -/******/ chunkIds.forEach((chunkId) => { -/******/ var href = __webpack_require__.miniCssF(chunkId); -/******/ var fullhref = __webpack_require__.p + href; -/******/ var oldTag = findStylesheet(href, fullhref); -/******/ if(!oldTag) return; -/******/ promises.push(new Promise((resolve, reject) => { -/******/ var tag = createStylesheet(chunkId, fullhref, () => { -/******/ tag.as = "style"; -/******/ tag.rel = "preload"; -/******/ resolve(); -/******/ }, reject); -/******/ oldTags.push(oldTag); -/******/ newTags.push(tag); -/******/ })); -/******/ }); -/******/ } -/******/ })(); -/******/ -/******/ /* webpack/runtime/jsonp chunk loading */ -/******/ (() => { -/******/ // no baseURI -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ // no chunk on demand loading -/******/ -/******/ // no prefetching -/******/ -/******/ // no preloaded -/******/ -/******/ var currentUpdatedModulesList; -/******/ var waitingUpdateResolves = {}; -/******/ function loadUpdateChunk(chunkId) { -/******/ return new Promise((resolve, reject) => { -/******/ waitingUpdateResolves[chunkId] = resolve; -/******/ // start update chunk loading -/******/ var url = __webpack_require__.p + __webpack_require__.hu(chunkId); -/******/ // create error before stack unwound to get useful stacktrace later -/******/ var error = new Error(); -/******/ var loadingEnded = (event) => { -/******/ if(waitingUpdateResolves[chunkId]) { -/******/ waitingUpdateResolves[chunkId] = undefined -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realSrc = event && event.target && event.target.src; -/******/ error.message = 'Loading hot update chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')'; -/******/ error.name = 'ChunkLoadError'; -/******/ error.type = errorType; -/******/ error.request = realSrc; -/******/ reject(error); -/******/ } -/******/ }; -/******/ __webpack_require__.l(url, loadingEnded); -/******/ }); -/******/ } -/******/ -/******/ self["webpackHotUpdate"] = (chunkId, moreModules, runtime) => { -/******/ for(var moduleId in moreModules) { -/******/ if(__webpack_require__.o(moreModules, moduleId)) { -/******/ currentUpdate[moduleId] = moreModules[moduleId]; -/******/ if(currentUpdatedModulesList) currentUpdatedModulesList.push(moduleId); -/******/ } -/******/ } -/******/ if(runtime) currentUpdateRuntime.push(runtime); -/******/ if(waitingUpdateResolves[chunkId]) { -/******/ waitingUpdateResolves[chunkId](); -/******/ waitingUpdateResolves[chunkId] = undefined; -/******/ } -/******/ }; -/******/ -/******/ var currentUpdateChunks; -/******/ var currentUpdate; -/******/ var currentUpdateRemovedChunks; -/******/ var currentUpdateRuntime; -/******/ function applyHandler(options) { -/******/ if (__webpack_require__.f) delete __webpack_require__.f.jsonpHmr; -/******/ currentUpdateChunks = undefined; -/******/ function getAffectedModuleEffects(updateModuleId) { -/******/ var outdatedModules = [updateModuleId]; -/******/ var outdatedDependencies = {}; -/******/ -/******/ var queue = outdatedModules.map(function (id) { -/******/ return { -/******/ chain: [id], -/******/ id: id -/******/ }; -/******/ }); -/******/ while (queue.length > 0) { -/******/ var queueItem = queue.pop(); -/******/ var moduleId = queueItem.id; -/******/ var chain = queueItem.chain; -/******/ var module = __webpack_require__.c[moduleId]; -/******/ if ( -/******/ !module || -/******/ (module.hot._selfAccepted && !module.hot._selfInvalidated) -/******/ ) -/******/ continue; -/******/ if (module.hot._selfDeclined) { -/******/ return { -/******/ type: "self-declined", -/******/ chain: chain, -/******/ moduleId: moduleId -/******/ }; -/******/ } -/******/ if (module.hot._main) { -/******/ return { -/******/ type: "unaccepted", -/******/ chain: chain, -/******/ moduleId: moduleId -/******/ }; -/******/ } -/******/ for (var i = 0; i < module.parents.length; i++) { -/******/ var parentId = module.parents[i]; -/******/ var parent = __webpack_require__.c[parentId]; -/******/ if (!parent) continue; -/******/ if (parent.hot._declinedDependencies[moduleId]) { -/******/ return { -/******/ type: "declined", -/******/ chain: chain.concat([parentId]), -/******/ moduleId: moduleId, -/******/ parentId: parentId -/******/ }; -/******/ } -/******/ if (outdatedModules.indexOf(parentId) !== -1) continue; -/******/ if (parent.hot._acceptedDependencies[moduleId]) { -/******/ if (!outdatedDependencies[parentId]) -/******/ outdatedDependencies[parentId] = []; -/******/ addAllToSet(outdatedDependencies[parentId], [moduleId]); -/******/ continue; -/******/ } -/******/ delete outdatedDependencies[parentId]; -/******/ outdatedModules.push(parentId); -/******/ queue.push({ -/******/ chain: chain.concat([parentId]), -/******/ id: parentId -/******/ }); -/******/ } -/******/ } -/******/ -/******/ return { -/******/ type: "accepted", -/******/ moduleId: updateModuleId, -/******/ outdatedModules: outdatedModules, -/******/ outdatedDependencies: outdatedDependencies -/******/ }; -/******/ } -/******/ -/******/ function addAllToSet(a, b) { -/******/ for (var i = 0; i < b.length; i++) { -/******/ var item = b[i]; -/******/ if (a.indexOf(item) === -1) a.push(item); -/******/ } -/******/ } -/******/ -/******/ // at begin all updates modules are outdated -/******/ // the "outdated" status can propagate to parents if they don't accept the children -/******/ var outdatedDependencies = {}; -/******/ var outdatedModules = []; -/******/ var appliedUpdate = {}; -/******/ -/******/ var warnUnexpectedRequire = function warnUnexpectedRequire(module) { -/******/ console.warn( -/******/ "[HMR] unexpected require(" + module.id + ") to disposed module" -/******/ ); -/******/ }; -/******/ -/******/ for (var moduleId in currentUpdate) { -/******/ if (__webpack_require__.o(currentUpdate, moduleId)) { -/******/ var newModuleFactory = currentUpdate[moduleId]; -/******/ /** @type {TODO} */ -/******/ var result; -/******/ if (newModuleFactory) { -/******/ result = getAffectedModuleEffects(moduleId); -/******/ } else { -/******/ result = { -/******/ type: "disposed", -/******/ moduleId: moduleId -/******/ }; -/******/ } -/******/ /** @type {Error|false} */ -/******/ var abortError = false; -/******/ var doApply = false; -/******/ var doDispose = false; -/******/ var chainInfo = ""; -/******/ if (result.chain) { -/******/ chainInfo = "\nUpdate propagation: " + result.chain.join(" -> "); -/******/ } -/******/ switch (result.type) { -/******/ case "self-declined": -/******/ if (options.onDeclined) options.onDeclined(result); -/******/ if (!options.ignoreDeclined) -/******/ abortError = new Error( -/******/ "Aborted because of self decline: " + -/******/ result.moduleId + -/******/ chainInfo -/******/ ); -/******/ break; -/******/ case "declined": -/******/ if (options.onDeclined) options.onDeclined(result); -/******/ if (!options.ignoreDeclined) -/******/ abortError = new Error( -/******/ "Aborted because of declined dependency: " + -/******/ result.moduleId + -/******/ " in " + -/******/ result.parentId + -/******/ chainInfo -/******/ ); -/******/ break; -/******/ case "unaccepted": -/******/ if (options.onUnaccepted) options.onUnaccepted(result); -/******/ if (!options.ignoreUnaccepted) -/******/ abortError = new Error( -/******/ "Aborted because " + moduleId + " is not accepted" + chainInfo -/******/ ); -/******/ break; -/******/ case "accepted": -/******/ if (options.onAccepted) options.onAccepted(result); -/******/ doApply = true; -/******/ break; -/******/ case "disposed": -/******/ if (options.onDisposed) options.onDisposed(result); -/******/ doDispose = true; -/******/ break; -/******/ default: -/******/ throw new Error("Unexception type " + result.type); -/******/ } -/******/ if (abortError) { -/******/ return { -/******/ error: abortError -/******/ }; -/******/ } -/******/ if (doApply) { -/******/ appliedUpdate[moduleId] = newModuleFactory; -/******/ addAllToSet(outdatedModules, result.outdatedModules); -/******/ for (moduleId in result.outdatedDependencies) { -/******/ if (__webpack_require__.o(result.outdatedDependencies, moduleId)) { -/******/ if (!outdatedDependencies[moduleId]) -/******/ outdatedDependencies[moduleId] = []; -/******/ addAllToSet( -/******/ outdatedDependencies[moduleId], -/******/ result.outdatedDependencies[moduleId] -/******/ ); -/******/ } -/******/ } -/******/ } -/******/ if (doDispose) { -/******/ addAllToSet(outdatedModules, [result.moduleId]); -/******/ appliedUpdate[moduleId] = warnUnexpectedRequire; -/******/ } -/******/ } -/******/ } -/******/ currentUpdate = undefined; -/******/ -/******/ // Store self accepted outdated modules to require them later by the module system -/******/ var outdatedSelfAcceptedModules = []; -/******/ for (var j = 0; j < outdatedModules.length; j++) { -/******/ var outdatedModuleId = outdatedModules[j]; -/******/ var module = __webpack_require__.c[outdatedModuleId]; -/******/ if ( -/******/ module && -/******/ (module.hot._selfAccepted || module.hot._main) && -/******/ // removed self-accepted modules should not be required -/******/ appliedUpdate[outdatedModuleId] !== warnUnexpectedRequire && -/******/ // when called invalidate self-accepting is not possible -/******/ !module.hot._selfInvalidated -/******/ ) { -/******/ outdatedSelfAcceptedModules.push({ -/******/ module: outdatedModuleId, -/******/ require: module.hot._requireSelf, -/******/ errorHandler: module.hot._selfAccepted -/******/ }); -/******/ } -/******/ } -/******/ -/******/ var moduleOutdatedDependencies; -/******/ -/******/ return { -/******/ dispose: function () { -/******/ currentUpdateRemovedChunks.forEach(function (chunkId) { -/******/ delete installedChunks[chunkId]; -/******/ }); -/******/ currentUpdateRemovedChunks = undefined; -/******/ -/******/ var idx; -/******/ var queue = outdatedModules.slice(); -/******/ while (queue.length > 0) { -/******/ var moduleId = queue.pop(); -/******/ var module = __webpack_require__.c[moduleId]; -/******/ if (!module) continue; -/******/ -/******/ var data = {}; -/******/ -/******/ // Call dispose handlers -/******/ var disposeHandlers = module.hot._disposeHandlers; -/******/ for (j = 0; j < disposeHandlers.length; j++) { -/******/ disposeHandlers[j].call(null, data); -/******/ } -/******/ __webpack_require__.hmrD[moduleId] = data; -/******/ -/******/ // disable module (this disables requires from this module) -/******/ module.hot.active = false; -/******/ -/******/ // remove module from cache -/******/ delete __webpack_require__.c[moduleId]; -/******/ -/******/ // when disposing there is no need to call dispose handler -/******/ delete outdatedDependencies[moduleId]; -/******/ -/******/ // remove "parents" references from all children -/******/ for (j = 0; j < module.children.length; j++) { -/******/ var child = __webpack_require__.c[module.children[j]]; -/******/ if (!child) continue; -/******/ idx = child.parents.indexOf(moduleId); -/******/ if (idx >= 0) { -/******/ child.parents.splice(idx, 1); -/******/ } -/******/ } -/******/ } -/******/ -/******/ // remove outdated dependency from module children -/******/ var dependency; -/******/ for (var outdatedModuleId in outdatedDependencies) { -/******/ if (__webpack_require__.o(outdatedDependencies, outdatedModuleId)) { -/******/ module = __webpack_require__.c[outdatedModuleId]; -/******/ if (module) { -/******/ moduleOutdatedDependencies = -/******/ outdatedDependencies[outdatedModuleId]; -/******/ for (j = 0; j < moduleOutdatedDependencies.length; j++) { -/******/ dependency = moduleOutdatedDependencies[j]; -/******/ idx = module.children.indexOf(dependency); -/******/ if (idx >= 0) module.children.splice(idx, 1); -/******/ } -/******/ } -/******/ } -/******/ } -/******/ }, -/******/ apply: function (reportError) { -/******/ // insert new code -/******/ for (var updateModuleId in appliedUpdate) { -/******/ if (__webpack_require__.o(appliedUpdate, updateModuleId)) { -/******/ __webpack_require__.m[updateModuleId] = appliedUpdate[updateModuleId]; -/******/ } -/******/ } -/******/ -/******/ // run new runtime modules -/******/ for (var i = 0; i < currentUpdateRuntime.length; i++) { -/******/ currentUpdateRuntime[i](__webpack_require__); -/******/ } -/******/ -/******/ // call accept handlers -/******/ for (var outdatedModuleId in outdatedDependencies) { -/******/ if (__webpack_require__.o(outdatedDependencies, outdatedModuleId)) { -/******/ var module = __webpack_require__.c[outdatedModuleId]; -/******/ if (module) { -/******/ moduleOutdatedDependencies = -/******/ outdatedDependencies[outdatedModuleId]; -/******/ var callbacks = []; -/******/ var errorHandlers = []; -/******/ var dependenciesForCallbacks = []; -/******/ for (var j = 0; j < moduleOutdatedDependencies.length; j++) { -/******/ var dependency = moduleOutdatedDependencies[j]; -/******/ var acceptCallback = -/******/ module.hot._acceptedDependencies[dependency]; -/******/ var errorHandler = -/******/ module.hot._acceptedErrorHandlers[dependency]; -/******/ if (acceptCallback) { -/******/ if (callbacks.indexOf(acceptCallback) !== -1) continue; -/******/ callbacks.push(acceptCallback); -/******/ errorHandlers.push(errorHandler); -/******/ dependenciesForCallbacks.push(dependency); -/******/ } -/******/ } -/******/ for (var k = 0; k < callbacks.length; k++) { -/******/ try { -/******/ callbacks[k].call(null, moduleOutdatedDependencies); -/******/ } catch (err) { -/******/ if (typeof errorHandlers[k] === "function") { -/******/ try { -/******/ errorHandlers[k](err, { -/******/ moduleId: outdatedModuleId, -/******/ dependencyId: dependenciesForCallbacks[k] -/******/ }); -/******/ } catch (err2) { -/******/ if (options.onErrored) { -/******/ options.onErrored({ -/******/ type: "accept-error-handler-errored", -/******/ moduleId: outdatedModuleId, -/******/ dependencyId: dependenciesForCallbacks[k], -/******/ error: err2, -/******/ originalError: err -/******/ }); -/******/ } -/******/ if (!options.ignoreErrored) { -/******/ reportError(err2); -/******/ reportError(err); -/******/ } -/******/ } -/******/ } else { -/******/ if (options.onErrored) { -/******/ options.onErrored({ -/******/ type: "accept-errored", -/******/ moduleId: outdatedModuleId, -/******/ dependencyId: dependenciesForCallbacks[k], -/******/ error: err -/******/ }); -/******/ } -/******/ if (!options.ignoreErrored) { -/******/ reportError(err); -/******/ } -/******/ } -/******/ } -/******/ } -/******/ } -/******/ } -/******/ } -/******/ -/******/ // Load self accepted modules -/******/ for (var o = 0; o < outdatedSelfAcceptedModules.length; o++) { -/******/ var item = outdatedSelfAcceptedModules[o]; -/******/ var moduleId = item.module; -/******/ try { -/******/ item.require(moduleId); -/******/ } catch (err) { -/******/ if (typeof item.errorHandler === "function") { -/******/ try { -/******/ item.errorHandler(err, { -/******/ moduleId: moduleId, -/******/ module: __webpack_require__.c[moduleId] -/******/ }); -/******/ } catch (err2) { -/******/ if (options.onErrored) { -/******/ options.onErrored({ -/******/ type: "self-accept-error-handler-errored", -/******/ moduleId: moduleId, -/******/ error: err2, -/******/ originalError: err -/******/ }); -/******/ } -/******/ if (!options.ignoreErrored) { -/******/ reportError(err2); -/******/ reportError(err); -/******/ } -/******/ } -/******/ } else { -/******/ if (options.onErrored) { -/******/ options.onErrored({ -/******/ type: "self-accept-errored", -/******/ moduleId: moduleId, -/******/ error: err -/******/ }); -/******/ } -/******/ if (!options.ignoreErrored) { -/******/ reportError(err); -/******/ } -/******/ } -/******/ } -/******/ } -/******/ -/******/ return outdatedModules; -/******/ } -/******/ }; -/******/ } -/******/ __webpack_require__.hmrI.jsonp = function (moduleId, applyHandlers) { -/******/ if (!currentUpdate) { -/******/ currentUpdate = {}; -/******/ currentUpdateRuntime = []; -/******/ currentUpdateRemovedChunks = []; -/******/ applyHandlers.push(applyHandler); -/******/ } -/******/ if (!__webpack_require__.o(currentUpdate, moduleId)) { -/******/ currentUpdate[moduleId] = __webpack_require__.m[moduleId]; -/******/ } -/******/ }; -/******/ __webpack_require__.hmrC.jsonp = function ( -/******/ chunkIds, -/******/ removedChunks, -/******/ removedModules, -/******/ promises, -/******/ applyHandlers, -/******/ updatedModulesList -/******/ ) { -/******/ applyHandlers.push(applyHandler); -/******/ currentUpdateChunks = {}; -/******/ currentUpdateRemovedChunks = removedChunks; -/******/ currentUpdate = removedModules.reduce(function (obj, key) { -/******/ obj[key] = false; -/******/ return obj; -/******/ }, {}); -/******/ currentUpdateRuntime = []; -/******/ chunkIds.forEach(function (chunkId) { -/******/ if ( -/******/ __webpack_require__.o(installedChunks, chunkId) && -/******/ installedChunks[chunkId] !== undefined -/******/ ) { -/******/ promises.push(loadUpdateChunk(chunkId, updatedModulesList)); -/******/ currentUpdateChunks[chunkId] = true; -/******/ } -/******/ }); -/******/ if (__webpack_require__.f) { -/******/ __webpack_require__.f.jsonpHmr = function (chunkId, promises) { -/******/ if ( -/******/ currentUpdateChunks && -/******/ !__webpack_require__.o(currentUpdateChunks, chunkId) && -/******/ __webpack_require__.o(installedChunks, chunkId) && -/******/ installedChunks[chunkId] !== undefined -/******/ ) { -/******/ promises.push(loadUpdateChunk(chunkId)); -/******/ currentUpdateChunks[chunkId] = true; -/******/ } -/******/ }; -/******/ } -/******/ }; -/******/ -/******/ __webpack_require__.hmrM = () => { -/******/ if (typeof fetch === "undefined") throw new Error("No browser support: need fetch API"); -/******/ return fetch(__webpack_require__.p + __webpack_require__.hmrF()).then((response) => { -/******/ if(response.status === 404) return; // no update available -/******/ if(!response.ok) throw new Error("Failed to fetch update manifest " + response.statusText); -/******/ return response.json(); -/******/ }); -/******/ }; -/******/ -/******/ // no on chunks loaded -/******/ -/******/ // no jsonp function -/******/ })(); -/******/ -/************************************************************************/ -/******/ -/******/ // module cache are used so entry inlining is disabled -/******/ // startup -/******/ // Load entry module and return exports -/******/ var __webpack_exports__ = __webpack_require__(0); -/******/ -/******/ })() -; \ No newline at end of file diff --git a/test/cases/insert-function/expected/webpack-5-importModule/1.css b/test/cases/insert-function/expected/1.css similarity index 100% rename from test/cases/insert-function/expected/webpack-5-importModule/1.css rename to test/cases/insert-function/expected/1.css diff --git a/test/cases/insert-function/expected/webpack-5-importModule/1.js b/test/cases/insert-function/expected/1.js similarity index 100% rename from test/cases/insert-function/expected/webpack-5-importModule/1.js rename to test/cases/insert-function/expected/1.js diff --git a/test/cases/insert-function/expected/webpack-5-importModule/main.js b/test/cases/insert-function/expected/main.js similarity index 100% rename from test/cases/insert-function/expected/webpack-5-importModule/main.js rename to test/cases/insert-function/expected/main.js diff --git a/test/cases/insert-function/expected/webpack-5/main.js b/test/cases/insert-function/expected/webpack-5/main.js deleted file mode 100644 index 98c4fdfa..00000000 --- a/test/cases/insert-function/expected/webpack-5/main.js +++ /dev/null @@ -1,331 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ var __webpack_modules__ = ({}); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = __webpack_modules__; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/ensure chunk */ -/******/ (() => { -/******/ __webpack_require__.f = {}; -/******/ // This file contains only the entry chunk. -/******/ // The chunk loading function for additional chunks -/******/ __webpack_require__.e = (chunkId) => { -/******/ return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => { -/******/ __webpack_require__.f[key](chunkId, promises); -/******/ return promises; -/******/ }, [])); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get javascript chunk filename */ -/******/ (() => { -/******/ // This function allow to reference async chunks -/******/ __webpack_require__.u = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + chunkId + ".js"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get mini-css chunk filename */ -/******/ (() => { -/******/ // This function allow to reference all chunks -/******/ __webpack_require__.miniCssF = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + chunkId + ".css"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/global */ -/******/ (() => { -/******/ __webpack_require__.g = (function() { -/******/ if (typeof globalThis === 'object') return globalThis; -/******/ try { -/******/ return this || new Function('return this')(); -/******/ } catch (e) { -/******/ if (typeof window === 'object') return window; -/******/ } -/******/ })(); -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/load script */ -/******/ (() => { -/******/ var inProgress = {}; -/******/ // data-webpack is not used as build has no uniqueName -/******/ // loadScript function to load a script via script tag -/******/ __webpack_require__.l = (url, done, key, chunkId) => { -/******/ if(inProgress[url]) { inProgress[url].push(done); return; } -/******/ var script, needAttach; -/******/ if(key !== undefined) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ for(var i = 0; i < scripts.length; i++) { -/******/ var s = scripts[i]; -/******/ if(s.getAttribute("src") == url) { script = s; break; } -/******/ } -/******/ } -/******/ if(!script) { -/******/ needAttach = true; -/******/ script = document.createElement('script'); -/******/ -/******/ script.charset = 'utf-8'; -/******/ script.timeout = 120; -/******/ if (__webpack_require__.nc) { -/******/ script.setAttribute("nonce", __webpack_require__.nc); -/******/ } -/******/ -/******/ script.src = url; -/******/ } -/******/ inProgress[url] = [done]; -/******/ var onScriptComplete = (prev, event) => { -/******/ // avoid mem leaks in IE. -/******/ script.onerror = script.onload = null; -/******/ clearTimeout(timeout); -/******/ var doneFns = inProgress[url]; -/******/ delete inProgress[url]; -/******/ script.parentNode && script.parentNode.removeChild(script); -/******/ doneFns && doneFns.forEach((fn) => (fn(event))); -/******/ if(prev) return prev(event); -/******/ } -/******/ ; -/******/ var timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000); -/******/ script.onerror = onScriptComplete.bind(null, script.onerror); -/******/ script.onload = onScriptComplete.bind(null, script.onload); -/******/ needAttach && document.head.appendChild(script); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/publicPath */ -/******/ (() => { -/******/ var scriptUrl; -/******/ if (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + ""; -/******/ var document = __webpack_require__.g.document; -/******/ if (!scriptUrl && document) { -/******/ if (document.currentScript) -/******/ scriptUrl = document.currentScript.src -/******/ if (!scriptUrl) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ if(scripts.length) scriptUrl = scripts[scripts.length - 1].src -/******/ } -/******/ } -/******/ // When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration -/******/ // or pass an empty string ("") and set the __webpack_public_path__ variable from your code to use your own logic. -/******/ if (!scriptUrl) throw new Error("Automatic publicPath is not supported in this browser"); -/******/ scriptUrl = scriptUrl.replace(/#.*$/, "").replace(/\?.*$/, "").replace(/\/[^\/]+$/, "/"); -/******/ __webpack_require__.p = scriptUrl; -/******/ })(); -/******/ -/******/ /* webpack/runtime/css loading */ -/******/ (() => { -/******/ var createStylesheet = (chunkId, fullhref, resolve, reject) => { -/******/ var linkTag = document.createElement("link"); -/******/ -/******/ linkTag.rel = "stylesheet"; -/******/ linkTag.type = "text/css"; -/******/ var onLinkComplete = (event) => { -/******/ // avoid mem leaks. -/******/ linkTag.onerror = linkTag.onload = null; -/******/ if (event.type === 'load') { -/******/ resolve(); -/******/ } else { -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realHref = event && event.target && event.target.href || fullhref; -/******/ var err = new Error("Loading CSS chunk " + chunkId + " failed.\n(" + realHref + ")"); -/******/ err.code = "CSS_CHUNK_LOAD_FAILED"; -/******/ err.type = errorType; -/******/ err.request = realHref; -/******/ linkTag.parentNode.removeChild(linkTag) -/******/ reject(err); -/******/ } -/******/ } -/******/ linkTag.onerror = linkTag.onload = onLinkComplete; -/******/ linkTag.href = fullhref; -/******/ -/******/ (function (linkTag) { -/******/ const reference = document.querySelector(".hot-reload"); -/******/ -/******/ if (reference) { -/******/ reference.parentNode.insertBefore(linkTag, reference); -/******/ } -/******/ })(linkTag) -/******/ return linkTag; -/******/ }; -/******/ var findStylesheet = (href, fullhref) => { -/******/ var existingLinkTags = document.getElementsByTagName("link"); -/******/ for(var i = 0; i < existingLinkTags.length; i++) { -/******/ var tag = existingLinkTags[i]; -/******/ var dataHref = tag.getAttribute("data-href") || tag.getAttribute("href"); -/******/ if(tag.rel === "stylesheet" && (dataHref === href || dataHref === fullhref)) return tag; -/******/ } -/******/ var existingStyleTags = document.getElementsByTagName("style"); -/******/ for(var i = 0; i < existingStyleTags.length; i++) { -/******/ var tag = existingStyleTags[i]; -/******/ var dataHref = tag.getAttribute("data-href"); -/******/ if(dataHref === href || dataHref === fullhref) return tag; -/******/ } -/******/ }; -/******/ var loadStylesheet = (chunkId) => { -/******/ return new Promise((resolve, reject) => { -/******/ var href = __webpack_require__.miniCssF(chunkId); -/******/ var fullhref = __webpack_require__.p + href; -/******/ if(findStylesheet(href, fullhref)) return resolve(); -/******/ createStylesheet(chunkId, fullhref, resolve, reject); -/******/ }); -/******/ } -/******/ // object to store loaded CSS chunks -/******/ var installedCssChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ __webpack_require__.f.miniCss = (chunkId, promises) => { -/******/ var cssChunks = {"1":1}; -/******/ if(installedCssChunks[chunkId]) promises.push(installedCssChunks[chunkId]); -/******/ else if(installedCssChunks[chunkId] !== 0 && cssChunks[chunkId]) { -/******/ promises.push(installedCssChunks[chunkId] = loadStylesheet(chunkId).then(() => { -/******/ installedCssChunks[chunkId] = 0; -/******/ }, (e) => { -/******/ delete installedCssChunks[chunkId]; -/******/ throw e; -/******/ })); -/******/ } -/******/ }; -/******/ -/******/ // no hmr -/******/ })(); -/******/ -/******/ /* webpack/runtime/jsonp chunk loading */ -/******/ (() => { -/******/ // no baseURI -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ __webpack_require__.f.j = (chunkId, promises) => { -/******/ // JSONP chunk loading for javascript -/******/ var installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined; -/******/ if(installedChunkData !== 0) { // 0 means "already installed". -/******/ -/******/ // a Promise means "currently loading". -/******/ if(installedChunkData) { -/******/ promises.push(installedChunkData[2]); -/******/ } else { -/******/ if(true) { // all chunks have JS -/******/ // setup Promise in chunk cache -/******/ var promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject])); -/******/ promises.push(installedChunkData[2] = promise); -/******/ -/******/ // start chunk loading -/******/ var url = __webpack_require__.p + __webpack_require__.u(chunkId); -/******/ // create error before stack unwound to get useful stacktrace later -/******/ var error = new Error(); -/******/ var loadingEnded = (event) => { -/******/ if(__webpack_require__.o(installedChunks, chunkId)) { -/******/ installedChunkData = installedChunks[chunkId]; -/******/ if(installedChunkData !== 0) installedChunks[chunkId] = undefined; -/******/ if(installedChunkData) { -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realSrc = event && event.target && event.target.src; -/******/ error.message = 'Loading chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')'; -/******/ error.name = 'ChunkLoadError'; -/******/ error.type = errorType; -/******/ error.request = realSrc; -/******/ installedChunkData[1](error); -/******/ } -/******/ } -/******/ }; -/******/ __webpack_require__.l(url, loadingEnded, "chunk-" + chunkId, chunkId); -/******/ } else installedChunks[chunkId] = 0; -/******/ } -/******/ } -/******/ }; -/******/ -/******/ // no prefetching -/******/ -/******/ // no preloaded -/******/ -/******/ // no HMR -/******/ -/******/ // no HMR manifest -/******/ -/******/ // no on chunks loaded -/******/ -/******/ // install a JSONP callback for chunk loading -/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { -/******/ var [chunkIds, moreModules, runtime] = data; -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0; -/******/ for(moduleId in moreModules) { -/******/ if(__webpack_require__.o(moreModules, moduleId)) { -/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(runtime) var result = runtime(__webpack_require__); -/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { -/******/ installedChunks[chunkId][0](); -/******/ } -/******/ installedChunks[chunkIds[i]] = 0; -/******/ } -/******/ -/******/ } -/******/ -/******/ var chunkLoadingGlobal = self["webpackChunk"] = self["webpackChunk"] || []; -/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); -/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -/* eslint-env browser */ - -// eslint-disable-next-line -__webpack_require__.e(/* import() */ 1).then(__webpack_require__.bind(__webpack_require__, 1)); - -/******/ })() -; \ No newline at end of file diff --git a/test/cases/insert-function/expected/webpack-5/1.css b/test/cases/insert-string/expected/1.css similarity index 100% rename from test/cases/insert-function/expected/webpack-5/1.css rename to test/cases/insert-string/expected/1.css diff --git a/test/cases/insert-function/expected/webpack-5/1.js b/test/cases/insert-string/expected/1.js similarity index 100% rename from test/cases/insert-function/expected/webpack-5/1.js rename to test/cases/insert-string/expected/1.js diff --git a/test/cases/insert-string/expected/webpack-5-importModule/main.js b/test/cases/insert-string/expected/main.js similarity index 100% rename from test/cases/insert-string/expected/webpack-5-importModule/main.js rename to test/cases/insert-string/expected/main.js diff --git a/test/cases/insert-string/expected/webpack-5/1.css b/test/cases/insert-string/expected/webpack-5/1.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/insert-string/expected/webpack-5/1.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/insert-string/expected/webpack-5/1.js b/test/cases/insert-string/expected/webpack-5/1.js deleted file mode 100644 index df8cbd2a..00000000 --- a/test/cases/insert-string/expected/webpack-5/1.js +++ /dev/null @@ -1,12 +0,0 @@ -(self["webpackChunk"] = self["webpackChunk"] || []).push([[1],[ -/* 0 */, -/* 1 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -]]); \ No newline at end of file diff --git a/test/cases/insert-string/expected/webpack-5/main.js b/test/cases/insert-string/expected/webpack-5/main.js deleted file mode 100644 index 3d10e93f..00000000 --- a/test/cases/insert-string/expected/webpack-5/main.js +++ /dev/null @@ -1,326 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ var __webpack_modules__ = ({}); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = __webpack_modules__; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/ensure chunk */ -/******/ (() => { -/******/ __webpack_require__.f = {}; -/******/ // This file contains only the entry chunk. -/******/ // The chunk loading function for additional chunks -/******/ __webpack_require__.e = (chunkId) => { -/******/ return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => { -/******/ __webpack_require__.f[key](chunkId, promises); -/******/ return promises; -/******/ }, [])); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get javascript chunk filename */ -/******/ (() => { -/******/ // This function allow to reference async chunks -/******/ __webpack_require__.u = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + chunkId + ".js"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get mini-css chunk filename */ -/******/ (() => { -/******/ // This function allow to reference all chunks -/******/ __webpack_require__.miniCssF = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + chunkId + ".css"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/global */ -/******/ (() => { -/******/ __webpack_require__.g = (function() { -/******/ if (typeof globalThis === 'object') return globalThis; -/******/ try { -/******/ return this || new Function('return this')(); -/******/ } catch (e) { -/******/ if (typeof window === 'object') return window; -/******/ } -/******/ })(); -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/load script */ -/******/ (() => { -/******/ var inProgress = {}; -/******/ // data-webpack is not used as build has no uniqueName -/******/ // loadScript function to load a script via script tag -/******/ __webpack_require__.l = (url, done, key, chunkId) => { -/******/ if(inProgress[url]) { inProgress[url].push(done); return; } -/******/ var script, needAttach; -/******/ if(key !== undefined) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ for(var i = 0; i < scripts.length; i++) { -/******/ var s = scripts[i]; -/******/ if(s.getAttribute("src") == url) { script = s; break; } -/******/ } -/******/ } -/******/ if(!script) { -/******/ needAttach = true; -/******/ script = document.createElement('script'); -/******/ -/******/ script.charset = 'utf-8'; -/******/ script.timeout = 120; -/******/ if (__webpack_require__.nc) { -/******/ script.setAttribute("nonce", __webpack_require__.nc); -/******/ } -/******/ -/******/ script.src = url; -/******/ } -/******/ inProgress[url] = [done]; -/******/ var onScriptComplete = (prev, event) => { -/******/ // avoid mem leaks in IE. -/******/ script.onerror = script.onload = null; -/******/ clearTimeout(timeout); -/******/ var doneFns = inProgress[url]; -/******/ delete inProgress[url]; -/******/ script.parentNode && script.parentNode.removeChild(script); -/******/ doneFns && doneFns.forEach((fn) => (fn(event))); -/******/ if(prev) return prev(event); -/******/ } -/******/ ; -/******/ var timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000); -/******/ script.onerror = onScriptComplete.bind(null, script.onerror); -/******/ script.onload = onScriptComplete.bind(null, script.onload); -/******/ needAttach && document.head.appendChild(script); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/publicPath */ -/******/ (() => { -/******/ var scriptUrl; -/******/ if (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + ""; -/******/ var document = __webpack_require__.g.document; -/******/ if (!scriptUrl && document) { -/******/ if (document.currentScript) -/******/ scriptUrl = document.currentScript.src -/******/ if (!scriptUrl) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ if(scripts.length) scriptUrl = scripts[scripts.length - 1].src -/******/ } -/******/ } -/******/ // When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration -/******/ // or pass an empty string ("") and set the __webpack_public_path__ variable from your code to use your own logic. -/******/ if (!scriptUrl) throw new Error("Automatic publicPath is not supported in this browser"); -/******/ scriptUrl = scriptUrl.replace(/#.*$/, "").replace(/\?.*$/, "").replace(/\/[^\/]+$/, "/"); -/******/ __webpack_require__.p = scriptUrl; -/******/ })(); -/******/ -/******/ /* webpack/runtime/css loading */ -/******/ (() => { -/******/ var createStylesheet = (chunkId, fullhref, resolve, reject) => { -/******/ var linkTag = document.createElement("link"); -/******/ -/******/ linkTag.rel = "stylesheet"; -/******/ linkTag.type = "text/css"; -/******/ var onLinkComplete = (event) => { -/******/ // avoid mem leaks. -/******/ linkTag.onerror = linkTag.onload = null; -/******/ if (event.type === 'load') { -/******/ resolve(); -/******/ } else { -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realHref = event && event.target && event.target.href || fullhref; -/******/ var err = new Error("Loading CSS chunk " + chunkId + " failed.\n(" + realHref + ")"); -/******/ err.code = "CSS_CHUNK_LOAD_FAILED"; -/******/ err.type = errorType; -/******/ err.request = realHref; -/******/ linkTag.parentNode.removeChild(linkTag) -/******/ reject(err); -/******/ } -/******/ } -/******/ linkTag.onerror = linkTag.onload = onLinkComplete; -/******/ linkTag.href = fullhref; -/******/ -/******/ var target = document.querySelector("script[src='1.js']"); -/******/ target.parentNode.insertBefore(linkTag, target.nextSibling); -/******/ return linkTag; -/******/ }; -/******/ var findStylesheet = (href, fullhref) => { -/******/ var existingLinkTags = document.getElementsByTagName("link"); -/******/ for(var i = 0; i < existingLinkTags.length; i++) { -/******/ var tag = existingLinkTags[i]; -/******/ var dataHref = tag.getAttribute("data-href") || tag.getAttribute("href"); -/******/ if(tag.rel === "stylesheet" && (dataHref === href || dataHref === fullhref)) return tag; -/******/ } -/******/ var existingStyleTags = document.getElementsByTagName("style"); -/******/ for(var i = 0; i < existingStyleTags.length; i++) { -/******/ var tag = existingStyleTags[i]; -/******/ var dataHref = tag.getAttribute("data-href"); -/******/ if(dataHref === href || dataHref === fullhref) return tag; -/******/ } -/******/ }; -/******/ var loadStylesheet = (chunkId) => { -/******/ return new Promise((resolve, reject) => { -/******/ var href = __webpack_require__.miniCssF(chunkId); -/******/ var fullhref = __webpack_require__.p + href; -/******/ if(findStylesheet(href, fullhref)) return resolve(); -/******/ createStylesheet(chunkId, fullhref, resolve, reject); -/******/ }); -/******/ } -/******/ // object to store loaded CSS chunks -/******/ var installedCssChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ __webpack_require__.f.miniCss = (chunkId, promises) => { -/******/ var cssChunks = {"1":1}; -/******/ if(installedCssChunks[chunkId]) promises.push(installedCssChunks[chunkId]); -/******/ else if(installedCssChunks[chunkId] !== 0 && cssChunks[chunkId]) { -/******/ promises.push(installedCssChunks[chunkId] = loadStylesheet(chunkId).then(() => { -/******/ installedCssChunks[chunkId] = 0; -/******/ }, (e) => { -/******/ delete installedCssChunks[chunkId]; -/******/ throw e; -/******/ })); -/******/ } -/******/ }; -/******/ -/******/ // no hmr -/******/ })(); -/******/ -/******/ /* webpack/runtime/jsonp chunk loading */ -/******/ (() => { -/******/ // no baseURI -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ __webpack_require__.f.j = (chunkId, promises) => { -/******/ // JSONP chunk loading for javascript -/******/ var installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined; -/******/ if(installedChunkData !== 0) { // 0 means "already installed". -/******/ -/******/ // a Promise means "currently loading". -/******/ if(installedChunkData) { -/******/ promises.push(installedChunkData[2]); -/******/ } else { -/******/ if(true) { // all chunks have JS -/******/ // setup Promise in chunk cache -/******/ var promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject])); -/******/ promises.push(installedChunkData[2] = promise); -/******/ -/******/ // start chunk loading -/******/ var url = __webpack_require__.p + __webpack_require__.u(chunkId); -/******/ // create error before stack unwound to get useful stacktrace later -/******/ var error = new Error(); -/******/ var loadingEnded = (event) => { -/******/ if(__webpack_require__.o(installedChunks, chunkId)) { -/******/ installedChunkData = installedChunks[chunkId]; -/******/ if(installedChunkData !== 0) installedChunks[chunkId] = undefined; -/******/ if(installedChunkData) { -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realSrc = event && event.target && event.target.src; -/******/ error.message = 'Loading chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')'; -/******/ error.name = 'ChunkLoadError'; -/******/ error.type = errorType; -/******/ error.request = realSrc; -/******/ installedChunkData[1](error); -/******/ } -/******/ } -/******/ }; -/******/ __webpack_require__.l(url, loadingEnded, "chunk-" + chunkId, chunkId); -/******/ } else installedChunks[chunkId] = 0; -/******/ } -/******/ } -/******/ }; -/******/ -/******/ // no prefetching -/******/ -/******/ // no preloaded -/******/ -/******/ // no HMR -/******/ -/******/ // no HMR manifest -/******/ -/******/ // no on chunks loaded -/******/ -/******/ // install a JSONP callback for chunk loading -/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { -/******/ var [chunkIds, moreModules, runtime] = data; -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0; -/******/ for(moduleId in moreModules) { -/******/ if(__webpack_require__.o(moreModules, moduleId)) { -/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(runtime) var result = runtime(__webpack_require__); -/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { -/******/ installedChunks[chunkId][0](); -/******/ } -/******/ installedChunks[chunkIds[i]] = 0; -/******/ } -/******/ -/******/ } -/******/ -/******/ var chunkLoadingGlobal = self["webpackChunk"] = self["webpackChunk"] || []; -/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); -/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -/* eslint-env browser */ - -// eslint-disable-next-line -__webpack_require__.e(/* import() */ 1).then(__webpack_require__.bind(__webpack_require__, 1)); - -/******/ })() -; \ No newline at end of file diff --git a/test/cases/insert-string/expected/webpack-5-importModule/1.css b/test/cases/insert-undefined/expected/1.css similarity index 100% rename from test/cases/insert-string/expected/webpack-5-importModule/1.css rename to test/cases/insert-undefined/expected/1.css diff --git a/test/cases/insert-string/expected/webpack-5-importModule/1.js b/test/cases/insert-undefined/expected/1.js similarity index 100% rename from test/cases/insert-string/expected/webpack-5-importModule/1.js rename to test/cases/insert-undefined/expected/1.js diff --git a/test/cases/insert-undefined/expected/webpack-5-importModule/main.js b/test/cases/insert-undefined/expected/main.js similarity index 100% rename from test/cases/insert-undefined/expected/webpack-5-importModule/main.js rename to test/cases/insert-undefined/expected/main.js diff --git a/test/cases/insert-undefined/expected/webpack-5-importModule/1.css b/test/cases/insert-undefined/expected/webpack-5-importModule/1.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/insert-undefined/expected/webpack-5-importModule/1.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/insert-undefined/expected/webpack-5-importModule/1.js b/test/cases/insert-undefined/expected/webpack-5-importModule/1.js deleted file mode 100644 index df8cbd2a..00000000 --- a/test/cases/insert-undefined/expected/webpack-5-importModule/1.js +++ /dev/null @@ -1,12 +0,0 @@ -(self["webpackChunk"] = self["webpackChunk"] || []).push([[1],[ -/* 0 */, -/* 1 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -]]); \ No newline at end of file diff --git a/test/cases/insert-undefined/expected/webpack-5/1.css b/test/cases/insert-undefined/expected/webpack-5/1.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/insert-undefined/expected/webpack-5/1.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/insert-undefined/expected/webpack-5/1.js b/test/cases/insert-undefined/expected/webpack-5/1.js deleted file mode 100644 index df8cbd2a..00000000 --- a/test/cases/insert-undefined/expected/webpack-5/1.js +++ /dev/null @@ -1,12 +0,0 @@ -(self["webpackChunk"] = self["webpackChunk"] || []).push([[1],[ -/* 0 */, -/* 1 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -]]); \ No newline at end of file diff --git a/test/cases/insert-undefined/expected/webpack-5/main.js b/test/cases/insert-undefined/expected/webpack-5/main.js deleted file mode 100644 index 54f0a25e..00000000 --- a/test/cases/insert-undefined/expected/webpack-5/main.js +++ /dev/null @@ -1,325 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ var __webpack_modules__ = ({}); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = __webpack_modules__; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/ensure chunk */ -/******/ (() => { -/******/ __webpack_require__.f = {}; -/******/ // This file contains only the entry chunk. -/******/ // The chunk loading function for additional chunks -/******/ __webpack_require__.e = (chunkId) => { -/******/ return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => { -/******/ __webpack_require__.f[key](chunkId, promises); -/******/ return promises; -/******/ }, [])); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get javascript chunk filename */ -/******/ (() => { -/******/ // This function allow to reference async chunks -/******/ __webpack_require__.u = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + chunkId + ".js"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get mini-css chunk filename */ -/******/ (() => { -/******/ // This function allow to reference all chunks -/******/ __webpack_require__.miniCssF = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + chunkId + ".css"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/global */ -/******/ (() => { -/******/ __webpack_require__.g = (function() { -/******/ if (typeof globalThis === 'object') return globalThis; -/******/ try { -/******/ return this || new Function('return this')(); -/******/ } catch (e) { -/******/ if (typeof window === 'object') return window; -/******/ } -/******/ })(); -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/load script */ -/******/ (() => { -/******/ var inProgress = {}; -/******/ // data-webpack is not used as build has no uniqueName -/******/ // loadScript function to load a script via script tag -/******/ __webpack_require__.l = (url, done, key, chunkId) => { -/******/ if(inProgress[url]) { inProgress[url].push(done); return; } -/******/ var script, needAttach; -/******/ if(key !== undefined) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ for(var i = 0; i < scripts.length; i++) { -/******/ var s = scripts[i]; -/******/ if(s.getAttribute("src") == url) { script = s; break; } -/******/ } -/******/ } -/******/ if(!script) { -/******/ needAttach = true; -/******/ script = document.createElement('script'); -/******/ -/******/ script.charset = 'utf-8'; -/******/ script.timeout = 120; -/******/ if (__webpack_require__.nc) { -/******/ script.setAttribute("nonce", __webpack_require__.nc); -/******/ } -/******/ -/******/ script.src = url; -/******/ } -/******/ inProgress[url] = [done]; -/******/ var onScriptComplete = (prev, event) => { -/******/ // avoid mem leaks in IE. -/******/ script.onerror = script.onload = null; -/******/ clearTimeout(timeout); -/******/ var doneFns = inProgress[url]; -/******/ delete inProgress[url]; -/******/ script.parentNode && script.parentNode.removeChild(script); -/******/ doneFns && doneFns.forEach((fn) => (fn(event))); -/******/ if(prev) return prev(event); -/******/ } -/******/ ; -/******/ var timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000); -/******/ script.onerror = onScriptComplete.bind(null, script.onerror); -/******/ script.onload = onScriptComplete.bind(null, script.onload); -/******/ needAttach && document.head.appendChild(script); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/publicPath */ -/******/ (() => { -/******/ var scriptUrl; -/******/ if (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + ""; -/******/ var document = __webpack_require__.g.document; -/******/ if (!scriptUrl && document) { -/******/ if (document.currentScript) -/******/ scriptUrl = document.currentScript.src -/******/ if (!scriptUrl) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ if(scripts.length) scriptUrl = scripts[scripts.length - 1].src -/******/ } -/******/ } -/******/ // When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration -/******/ // or pass an empty string ("") and set the __webpack_public_path__ variable from your code to use your own logic. -/******/ if (!scriptUrl) throw new Error("Automatic publicPath is not supported in this browser"); -/******/ scriptUrl = scriptUrl.replace(/#.*$/, "").replace(/\?.*$/, "").replace(/\/[^\/]+$/, "/"); -/******/ __webpack_require__.p = scriptUrl; -/******/ })(); -/******/ -/******/ /* webpack/runtime/css loading */ -/******/ (() => { -/******/ var createStylesheet = (chunkId, fullhref, resolve, reject) => { -/******/ var linkTag = document.createElement("link"); -/******/ -/******/ linkTag.rel = "stylesheet"; -/******/ linkTag.type = "text/css"; -/******/ var onLinkComplete = (event) => { -/******/ // avoid mem leaks. -/******/ linkTag.onerror = linkTag.onload = null; -/******/ if (event.type === 'load') { -/******/ resolve(); -/******/ } else { -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realHref = event && event.target && event.target.href || fullhref; -/******/ var err = new Error("Loading CSS chunk " + chunkId + " failed.\n(" + realHref + ")"); -/******/ err.code = "CSS_CHUNK_LOAD_FAILED"; -/******/ err.type = errorType; -/******/ err.request = realHref; -/******/ linkTag.parentNode.removeChild(linkTag) -/******/ reject(err); -/******/ } -/******/ } -/******/ linkTag.onerror = linkTag.onload = onLinkComplete; -/******/ linkTag.href = fullhref; -/******/ -/******/ document.head.appendChild(linkTag); -/******/ return linkTag; -/******/ }; -/******/ var findStylesheet = (href, fullhref) => { -/******/ var existingLinkTags = document.getElementsByTagName("link"); -/******/ for(var i = 0; i < existingLinkTags.length; i++) { -/******/ var tag = existingLinkTags[i]; -/******/ var dataHref = tag.getAttribute("data-href") || tag.getAttribute("href"); -/******/ if(tag.rel === "stylesheet" && (dataHref === href || dataHref === fullhref)) return tag; -/******/ } -/******/ var existingStyleTags = document.getElementsByTagName("style"); -/******/ for(var i = 0; i < existingStyleTags.length; i++) { -/******/ var tag = existingStyleTags[i]; -/******/ var dataHref = tag.getAttribute("data-href"); -/******/ if(dataHref === href || dataHref === fullhref) return tag; -/******/ } -/******/ }; -/******/ var loadStylesheet = (chunkId) => { -/******/ return new Promise((resolve, reject) => { -/******/ var href = __webpack_require__.miniCssF(chunkId); -/******/ var fullhref = __webpack_require__.p + href; -/******/ if(findStylesheet(href, fullhref)) return resolve(); -/******/ createStylesheet(chunkId, fullhref, resolve, reject); -/******/ }); -/******/ } -/******/ // object to store loaded CSS chunks -/******/ var installedCssChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ __webpack_require__.f.miniCss = (chunkId, promises) => { -/******/ var cssChunks = {"1":1}; -/******/ if(installedCssChunks[chunkId]) promises.push(installedCssChunks[chunkId]); -/******/ else if(installedCssChunks[chunkId] !== 0 && cssChunks[chunkId]) { -/******/ promises.push(installedCssChunks[chunkId] = loadStylesheet(chunkId).then(() => { -/******/ installedCssChunks[chunkId] = 0; -/******/ }, (e) => { -/******/ delete installedCssChunks[chunkId]; -/******/ throw e; -/******/ })); -/******/ } -/******/ }; -/******/ -/******/ // no hmr -/******/ })(); -/******/ -/******/ /* webpack/runtime/jsonp chunk loading */ -/******/ (() => { -/******/ // no baseURI -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ 0: 0 -/******/ }; -/******/ -/******/ __webpack_require__.f.j = (chunkId, promises) => { -/******/ // JSONP chunk loading for javascript -/******/ var installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined; -/******/ if(installedChunkData !== 0) { // 0 means "already installed". -/******/ -/******/ // a Promise means "currently loading". -/******/ if(installedChunkData) { -/******/ promises.push(installedChunkData[2]); -/******/ } else { -/******/ if(true) { // all chunks have JS -/******/ // setup Promise in chunk cache -/******/ var promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject])); -/******/ promises.push(installedChunkData[2] = promise); -/******/ -/******/ // start chunk loading -/******/ var url = __webpack_require__.p + __webpack_require__.u(chunkId); -/******/ // create error before stack unwound to get useful stacktrace later -/******/ var error = new Error(); -/******/ var loadingEnded = (event) => { -/******/ if(__webpack_require__.o(installedChunks, chunkId)) { -/******/ installedChunkData = installedChunks[chunkId]; -/******/ if(installedChunkData !== 0) installedChunks[chunkId] = undefined; -/******/ if(installedChunkData) { -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realSrc = event && event.target && event.target.src; -/******/ error.message = 'Loading chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')'; -/******/ error.name = 'ChunkLoadError'; -/******/ error.type = errorType; -/******/ error.request = realSrc; -/******/ installedChunkData[1](error); -/******/ } -/******/ } -/******/ }; -/******/ __webpack_require__.l(url, loadingEnded, "chunk-" + chunkId, chunkId); -/******/ } else installedChunks[chunkId] = 0; -/******/ } -/******/ } -/******/ }; -/******/ -/******/ // no prefetching -/******/ -/******/ // no preloaded -/******/ -/******/ // no HMR -/******/ -/******/ // no HMR manifest -/******/ -/******/ // no on chunks loaded -/******/ -/******/ // install a JSONP callback for chunk loading -/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { -/******/ var [chunkIds, moreModules, runtime] = data; -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0; -/******/ for(moduleId in moreModules) { -/******/ if(__webpack_require__.o(moreModules, moduleId)) { -/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(runtime) var result = runtime(__webpack_require__); -/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { -/******/ installedChunks[chunkId][0](); -/******/ } -/******/ installedChunks[chunkIds[i]] = 0; -/******/ } -/******/ -/******/ } -/******/ -/******/ var chunkLoadingGlobal = self["webpackChunk"] = self["webpackChunk"] || []; -/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); -/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -/* eslint-env browser */ - -// eslint-disable-next-line -__webpack_require__.e(/* import() */ 1).then(__webpack_require__.bind(__webpack_require__, 1)); - -/******/ })() -; \ No newline at end of file diff --git a/test/cases/multiple-compiler/expected/webpack-5-importModule/one-main.js b/test/cases/multiple-compiler/expected/one-main.js similarity index 100% rename from test/cases/multiple-compiler/expected/webpack-5-importModule/one-main.js rename to test/cases/multiple-compiler/expected/one-main.js diff --git a/test/cases/devtool-source-map-no-source-maps-from-loaders/expected/webpack-5-importModule/main.css b/test/cases/multiple-compiler/expected/one/main.css similarity index 100% rename from test/cases/devtool-source-map-no-source-maps-from-loaders/expected/webpack-5-importModule/main.css rename to test/cases/multiple-compiler/expected/one/main.css diff --git a/test/cases/multiple-compiler/expected/webpack-5-importModule/two-main.js b/test/cases/multiple-compiler/expected/two-main.js similarity index 100% rename from test/cases/multiple-compiler/expected/webpack-5-importModule/two-main.js rename to test/cases/multiple-compiler/expected/two-main.js diff --git a/test/cases/devtool-source-map-no-source-maps-from-loaders/expected/webpack-5/main.css b/test/cases/multiple-compiler/expected/two/main.css similarity index 100% rename from test/cases/devtool-source-map-no-source-maps-from-loaders/expected/webpack-5/main.css rename to test/cases/multiple-compiler/expected/two/main.css diff --git a/test/cases/multiple-compiler/expected/webpack-5-importModule/one/main.css b/test/cases/multiple-compiler/expected/webpack-5-importModule/one/main.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/multiple-compiler/expected/webpack-5-importModule/one/main.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/multiple-compiler/expected/webpack-5-importModule/two/main.css b/test/cases/multiple-compiler/expected/webpack-5-importModule/two/main.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/multiple-compiler/expected/webpack-5-importModule/two/main.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/multiple-compiler/expected/webpack-5/one-main.js b/test/cases/multiple-compiler/expected/webpack-5/one-main.js deleted file mode 100644 index adf06601..00000000 --- a/test/cases/multiple-compiler/expected/webpack-5/one-main.js +++ /dev/null @@ -1,62 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ var __webpack_modules__ = ([ -/* 0 */, -/* 1 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -/******/ ]); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. -(() => { -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _style_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1); - - -})(); - -/******/ })() -; \ No newline at end of file diff --git a/test/cases/multiple-compiler/expected/webpack-5/one/main.css b/test/cases/multiple-compiler/expected/webpack-5/one/main.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/multiple-compiler/expected/webpack-5/one/main.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/multiple-compiler/expected/webpack-5/two-main.js b/test/cases/multiple-compiler/expected/webpack-5/two-main.js deleted file mode 100644 index adf06601..00000000 --- a/test/cases/multiple-compiler/expected/webpack-5/two-main.js +++ /dev/null @@ -1,62 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ var __webpack_modules__ = ([ -/* 0 */, -/* 1 */ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }) -/******/ ]); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. -(() => { -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _style_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1); - - -})(); - -/******/ })() -; \ No newline at end of file diff --git a/test/cases/multiple-compiler/expected/webpack-5/two/main.css b/test/cases/multiple-compiler/expected/webpack-5/two/main.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/multiple-compiler/expected/webpack-5/two/main.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/runtime/expected/webpack-5-importModule/main.a45a4571ab5cece12cf0.css b/test/cases/runtime/expected/main.a45a4571ab5cece12cf0.css similarity index 100% rename from test/cases/runtime/expected/webpack-5-importModule/main.a45a4571ab5cece12cf0.css rename to test/cases/runtime/expected/main.a45a4571ab5cece12cf0.css diff --git a/test/cases/runtime/expected/webpack-5-importModule/runtime~main.js b/test/cases/runtime/expected/runtime~main.js similarity index 100% rename from test/cases/runtime/expected/webpack-5-importModule/runtime~main.js rename to test/cases/runtime/expected/runtime~main.js diff --git a/test/cases/runtime/expected/webpack-5/main.a45a4571ab5cece12cf0.css b/test/cases/runtime/expected/webpack-5/main.a45a4571ab5cece12cf0.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/runtime/expected/webpack-5/main.a45a4571ab5cece12cf0.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/runtime/expected/webpack-5/runtime~main.js b/test/cases/runtime/expected/webpack-5/runtime~main.js deleted file mode 100644 index 7e791603..00000000 --- a/test/cases/runtime/expected/webpack-5/runtime~main.js +++ /dev/null @@ -1,323 +0,0 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ var __webpack_modules__ = ({}); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = __webpack_modules__; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/chunk loaded */ -/******/ (() => { -/******/ var deferred = []; -/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { -/******/ if(chunkIds) { -/******/ priority = priority || 0; -/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; -/******/ deferred[i] = [chunkIds, fn, priority]; -/******/ return; -/******/ } -/******/ var notFulfilled = Infinity; -/******/ for (var i = 0; i < deferred.length; i++) { -/******/ var [chunkIds, fn, priority] = deferred[i]; -/******/ var fulfilled = true; -/******/ for (var j = 0; j < chunkIds.length; j++) { -/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { -/******/ chunkIds.splice(j--, 1); -/******/ } else { -/******/ fulfilled = false; -/******/ if(priority < notFulfilled) notFulfilled = priority; -/******/ } -/******/ } -/******/ if(fulfilled) { -/******/ deferred.splice(i--, 1) -/******/ result = fn(); -/******/ } -/******/ } -/******/ return result; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/create fake namespace object */ -/******/ (() => { -/******/ var getProto = Object.getPrototypeOf ? (obj) => (Object.getPrototypeOf(obj)) : (obj) => (obj.__proto__); -/******/ var leafPrototypes; -/******/ // create a fake namespace object -/******/ // mode & 1: value is a module id, require it -/******/ // mode & 2: merge all properties of value into the ns -/******/ // mode & 4: return value when already ns object -/******/ // mode & 16: return value when it's Promise-like -/******/ // mode & 8|1: behave like require -/******/ __webpack_require__.t = function(value, mode) { -/******/ if(mode & 1) value = this(value); -/******/ if(mode & 8) return value; -/******/ if(typeof value === 'object' && value) { -/******/ if((mode & 4) && value.__esModule) return value; -/******/ if((mode & 16) && typeof value.then === 'function') return value; -/******/ } -/******/ var ns = Object.create(null); -/******/ __webpack_require__.r(ns); -/******/ var def = {}; -/******/ leafPrototypes = leafPrototypes || [null, getProto({}), getProto([]), getProto(getProto)]; -/******/ for(var current = mode & 2 && value; typeof current == 'object' && !~leafPrototypes.indexOf(current); current = getProto(current)) { -/******/ Object.getOwnPropertyNames(current).forEach((key) => (def[key] = () => (value[key]))); -/******/ } -/******/ def['default'] = () => (value); -/******/ __webpack_require__.d(ns, def); -/******/ return ns; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/define property getters */ -/******/ (() => { -/******/ // define getter functions for harmony exports -/******/ __webpack_require__.d = (exports, definition) => { -/******/ for(var key in definition) { -/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { -/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); -/******/ } -/******/ } -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/ensure chunk */ -/******/ (() => { -/******/ __webpack_require__.f = {}; -/******/ // This file contains only the entry chunk. -/******/ // The chunk loading function for additional chunks -/******/ __webpack_require__.e = (chunkId) => { -/******/ return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => { -/******/ __webpack_require__.f[key](chunkId, promises); -/******/ return promises; -/******/ }, [])); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get javascript chunk filename */ -/******/ (() => { -/******/ // This function allow to reference async chunks -/******/ __webpack_require__.u = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + chunkId + ".js"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/get mini-css chunk filename */ -/******/ (() => { -/******/ // This function allow to reference all chunks -/******/ __webpack_require__.miniCssF = (chunkId) => { -/******/ // return url for filenames based on template -/******/ return "" + "main" + "." + "a45a4571ab5cece12cf0" + ".css"; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/global */ -/******/ (() => { -/******/ __webpack_require__.g = (function() { -/******/ if (typeof globalThis === 'object') return globalThis; -/******/ try { -/******/ return this || new Function('return this')(); -/******/ } catch (e) { -/******/ if (typeof window === 'object') return window; -/******/ } -/******/ })(); -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/load script */ -/******/ (() => { -/******/ var inProgress = {}; -/******/ // data-webpack is not used as build has no uniqueName -/******/ // loadScript function to load a script via script tag -/******/ __webpack_require__.l = (url, done, key, chunkId) => { -/******/ if(inProgress[url]) { inProgress[url].push(done); return; } -/******/ var script, needAttach; -/******/ if(key !== undefined) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ for(var i = 0; i < scripts.length; i++) { -/******/ var s = scripts[i]; -/******/ if(s.getAttribute("src") == url) { script = s; break; } -/******/ } -/******/ } -/******/ if(!script) { -/******/ needAttach = true; -/******/ script = document.createElement('script'); -/******/ -/******/ script.charset = 'utf-8'; -/******/ script.timeout = 120; -/******/ if (__webpack_require__.nc) { -/******/ script.setAttribute("nonce", __webpack_require__.nc); -/******/ } -/******/ -/******/ script.src = url; -/******/ } -/******/ inProgress[url] = [done]; -/******/ var onScriptComplete = (prev, event) => { -/******/ // avoid mem leaks in IE. -/******/ script.onerror = script.onload = null; -/******/ clearTimeout(timeout); -/******/ var doneFns = inProgress[url]; -/******/ delete inProgress[url]; -/******/ script.parentNode && script.parentNode.removeChild(script); -/******/ doneFns && doneFns.forEach((fn) => (fn(event))); -/******/ if(prev) return prev(event); -/******/ } -/******/ ; -/******/ var timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000); -/******/ script.onerror = onScriptComplete.bind(null, script.onerror); -/******/ script.onload = onScriptComplete.bind(null, script.onload); -/******/ needAttach && document.head.appendChild(script); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/publicPath */ -/******/ (() => { -/******/ var scriptUrl; -/******/ if (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + ""; -/******/ var document = __webpack_require__.g.document; -/******/ if (!scriptUrl && document) { -/******/ if (document.currentScript) -/******/ scriptUrl = document.currentScript.src -/******/ if (!scriptUrl) { -/******/ var scripts = document.getElementsByTagName("script"); -/******/ if(scripts.length) scriptUrl = scripts[scripts.length - 1].src -/******/ } -/******/ } -/******/ // When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration -/******/ // or pass an empty string ("") and set the __webpack_public_path__ variable from your code to use your own logic. -/******/ if (!scriptUrl) throw new Error("Automatic publicPath is not supported in this browser"); -/******/ scriptUrl = scriptUrl.replace(/#.*$/, "").replace(/\?.*$/, "").replace(/\/[^\/]+$/, "/"); -/******/ __webpack_require__.p = scriptUrl; -/******/ })(); -/******/ -/******/ /* webpack/runtime/jsonp chunk loading */ -/******/ (() => { -/******/ // no baseURI -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ 1: 0 -/******/ }; -/******/ -/******/ __webpack_require__.f.j = (chunkId, promises) => { -/******/ // JSONP chunk loading for javascript -/******/ var installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined; -/******/ if(installedChunkData !== 0) { // 0 means "already installed". -/******/ -/******/ // a Promise means "currently loading". -/******/ if(installedChunkData) { -/******/ promises.push(installedChunkData[2]); -/******/ } else { -/******/ if(1 != chunkId) { -/******/ // setup Promise in chunk cache -/******/ var promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject])); -/******/ promises.push(installedChunkData[2] = promise); -/******/ -/******/ // start chunk loading -/******/ var url = __webpack_require__.p + __webpack_require__.u(chunkId); -/******/ // create error before stack unwound to get useful stacktrace later -/******/ var error = new Error(); -/******/ var loadingEnded = (event) => { -/******/ if(__webpack_require__.o(installedChunks, chunkId)) { -/******/ installedChunkData = installedChunks[chunkId]; -/******/ if(installedChunkData !== 0) installedChunks[chunkId] = undefined; -/******/ if(installedChunkData) { -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); -/******/ var realSrc = event && event.target && event.target.src; -/******/ error.message = 'Loading chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')'; -/******/ error.name = 'ChunkLoadError'; -/******/ error.type = errorType; -/******/ error.request = realSrc; -/******/ installedChunkData[1](error); -/******/ } -/******/ } -/******/ }; -/******/ __webpack_require__.l(url, loadingEnded, "chunk-" + chunkId, chunkId); -/******/ } else installedChunks[chunkId] = 0; -/******/ } -/******/ } -/******/ }; -/******/ -/******/ // no prefetching -/******/ -/******/ // no preloaded -/******/ -/******/ // no HMR -/******/ -/******/ // no HMR manifest -/******/ -/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); -/******/ -/******/ // install a JSONP callback for chunk loading -/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { -/******/ var [chunkIds, moreModules, runtime] = data; -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0; -/******/ for(moduleId in moreModules) { -/******/ if(__webpack_require__.o(moreModules, moduleId)) { -/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(runtime) var result = runtime(__webpack_require__); -/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { -/******/ installedChunks[chunkId][0](); -/******/ } -/******/ installedChunks[chunkIds[i]] = 0; -/******/ } -/******/ return __webpack_require__.O(result); -/******/ } -/******/ -/******/ var chunkLoadingGlobal = self["webpackChunk"] = self["webpackChunk"] || []; -/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); -/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); -/******/ })(); -/******/ -/************************************************************************/ -/******/ -/******/ -/******/ })() -; \ No newline at end of file diff --git a/test/cases/split-chunks-all/expected/webpack-5-importModule/2.css b/test/cases/split-chunks-all/expected/2.css similarity index 100% rename from test/cases/split-chunks-all/expected/webpack-5-importModule/2.css rename to test/cases/split-chunks-all/expected/2.css diff --git a/test/cases/split-chunks-all/expected/webpack-5-importModule/2.js b/test/cases/split-chunks-all/expected/2.js similarity index 100% rename from test/cases/split-chunks-all/expected/webpack-5-importModule/2.js rename to test/cases/split-chunks-all/expected/2.js diff --git a/test/cases/split-chunks-all/expected/webpack-5/2.css b/test/cases/split-chunks-all/expected/webpack-5/2.css deleted file mode 100644 index cebc5c1c..00000000 --- a/test/cases/split-chunks-all/expected/webpack-5/2.css +++ /dev/null @@ -1,4 +0,0 @@ -body { - background: red; -} - diff --git a/test/cases/split-chunks-all/expected/webpack-5/2.js b/test/cases/split-chunks-all/expected/webpack-5/2.js deleted file mode 100644 index c8d4dd4f..00000000 --- a/test/cases/split-chunks-all/expected/webpack-5/2.js +++ /dev/null @@ -1 +0,0 @@ -MISSING