12345678910111213141516171819202122 |
- module.exports.getRefreshGlobalScope = (runtimeGlobals) => {
- return `${runtimeGlobals.require || '__webpack_require__'}.$Refresh$`;
- };
- module.exports.getWebpackVersion = (compiler) => {
- if (!compiler.hooks) {
- throw new Error(`[ReactRefreshPlugin] Webpack version is not supported!`);
- }
-
- return 'cache' in compiler ? 5 : 4;
- };
|