@@ -16,12 +16,12 @@ describe('loader', () => {
1616 const { execution, parsed } = compilation . module ;
1717
1818 expect ( parsed ) . toMatchInlineSnapshot ( `
19- "__webpack_require__.$Refresh$.runtime = require('react-refresh');
19+ "(typeof __webpack_global__ !== 'undefined' ? __webpack_global__ : __webpack_require__) .$Refresh$.runtime = require('react-refresh');
2020
2121 module.exports = 'Test';
2222
2323
24- var $ReactRefreshModuleId$ = __webpack_require__.$Refresh$.moduleId;
24+ var $ReactRefreshModuleId$ = (typeof __webpack_global__ !== 'undefined' ? __webpack_global__ : __webpack_require__) .$Refresh$.moduleId;
2525 var $ReactRefreshCurrentExports$ = __react_refresh_utils__.getModuleExports(
2626 $ReactRefreshModuleId$
2727 );
@@ -61,12 +61,12 @@ describe('loader', () => {
6161 \\******************/
6262 /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
6363
64- __webpack_require__.$Refresh$.runtime = __webpack_require__(/*! react-refresh */ "../../../../node_modules/react-refresh/runtime.js");
64+ (typeof __webpack_global__ !== 'undefined' ? __webpack_global__ : __webpack_require__) .$Refresh$.runtime = __webpack_require__(/*! react-refresh */ "../../../../node_modules/react-refresh/runtime.js");
6565
6666 module.exports = 'Test';
6767
6868
69- var $ReactRefreshModuleId$ = __webpack_require__.$Refresh$.moduleId;
69+ var $ReactRefreshModuleId$ = (typeof __webpack_global__ !== 'undefined' ? __webpack_global__ : __webpack_require__) .$Refresh$.moduleId;
7070 var $ReactRefreshCurrentExports$ = __react_refresh_utils__.getModuleExports(
7171 $ReactRefreshModuleId$
7272 );
@@ -118,12 +118,12 @@ describe('loader', () => {
118118
119119 expect ( parsed ) . toMatchInlineSnapshot ( `
120120 "import * as __react_refresh_runtime__ from 'react-refresh';
121- __webpack_require__.$Refresh$.runtime = __react_refresh_runtime__;
121+ (typeof __webpack_global__ !== 'undefined' ? __webpack_global__ : __webpack_require__) .$Refresh$.runtime = __react_refresh_runtime__;
122122
123123 export default 'Test';
124124
125125
126- var $ReactRefreshModuleId$ = __webpack_require__.$Refresh$.moduleId;
126+ var $ReactRefreshModuleId$ = (typeof __webpack_global__ !== 'undefined' ? __webpack_global__ : __webpack_require__) .$Refresh$.moduleId;
127127 var $ReactRefreshCurrentExports$ = __react_refresh_utils__.getModuleExports(
128128 $ReactRefreshModuleId$
129129 );
@@ -171,12 +171,12 @@ describe('loader', () => {
171171 /* harmony export */ });
172172 /* harmony import */ var react_refresh__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react-refresh */ "../../../../node_modules/react-refresh/runtime.js");
173173
174- __webpack_require__.$Refresh$.runtime = /*#__PURE__*/ (react_refresh__WEBPACK_IMPORTED_MODULE_0___namespace_cache || (react_refresh__WEBPACK_IMPORTED_MODULE_0___namespace_cache = __webpack_require__.t(react_refresh__WEBPACK_IMPORTED_MODULE_0__, 2)));
174+ (typeof __webpack_global__ !== 'undefined' ? __webpack_global__ : __webpack_require__) .$Refresh$.runtime = /*#__PURE__*/ (react_refresh__WEBPACK_IMPORTED_MODULE_0___namespace_cache || (react_refresh__WEBPACK_IMPORTED_MODULE_0___namespace_cache = __webpack_require__.t(react_refresh__WEBPACK_IMPORTED_MODULE_0__, 2)));
175175
176176 /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ('Test');
177177
178178
179- var $ReactRefreshModuleId$ = __webpack_require__.$Refresh$.moduleId;
179+ var $ReactRefreshModuleId$ = (typeof __webpack_global__ !== 'undefined' ? __webpack_global__ : __webpack_require__) .$Refresh$.moduleId;
180180 var $ReactRefreshCurrentExports$ = __react_refresh_utils__.getModuleExports(
181181 $ReactRefreshModuleId$
182182 );
0 commit comments