This repository was archived by the owner on Aug 7, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 5 files changed +7
-7
lines changed
Expand file tree Collapse file tree 5 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -12,13 +12,13 @@ module.exports = function (source) {
1212 hmrUpdate();
1313 };
1414
15- global.hmrRefresh = function({ type, module } = {}) {
15+ global.hmrRefresh = function({ type, path } = {}) {
1616 if (global.__initialHmrUpdate) {
1717 return;
1818 }
1919
2020 setTimeout(() => {
21- global.__hmrSyncBackup({ type, module });
21+ global.__hmrSyncBackup({ type, path });
2222 });
2323 };
2424
Original file line number Diff line number Diff line change 1- module . exports . reload = function ( { type, module } ) {
1+ module . exports . reload = function ( { type, path } ) {
22 return `
33 if (module.hot) {
44 module.hot.accept();
55 module.hot.dispose(() => {
6- global.hmrRefresh({ type: '${ type } ', module : '${ module } ' });
6+ global.hmrRefresh({ type: '${ type } ', path : '${ path } ' });
77 })
88 }
99` } ;
Original file line number Diff line number Diff line change @@ -3,5 +3,5 @@ const { reload } = require("./hot-loader-helper");
33module . exports = function ( source ) {
44 const typeMarkup = "markup" ;
55 const modulePath = this . resourcePath . replace ( this . rootContext , "." ) ;
6- return `${ source } ;${ reload ( { type : typeMarkup , module : modulePath } ) } ` ;
6+ return `${ source } ;${ reload ( { type : typeMarkup , path : modulePath } ) } ` ;
77} ;
Original file line number Diff line number Diff line change @@ -3,5 +3,5 @@ const { reload } = require("./hot-loader-helper");
33module . exports = function ( source ) {
44 const typeScript = "script" ;
55 const modulePath = this . resourcePath . replace ( this . rootContext , "." ) ;
6- return `${ source } ;${ reload ( { type : typeScript , module : modulePath } ) } ` ;
6+ return `${ source } ;${ reload ( { type : typeScript , path : modulePath } ) } ` ;
77} ;
Original file line number Diff line number Diff line change @@ -3,5 +3,5 @@ const { reload } = require("./hot-loader-helper");
33module . exports = function ( source ) {
44 const typeStyle = "style" ;
55 const modulePath = this . resourcePath . replace ( this . rootContext , "." ) ;
6- return `${ source } ;${ reload ( { type : typeStyle , module : modulePath } ) } ` ;
6+ return `${ source } ;${ reload ( { type : typeStyle , path : modulePath } ) } ` ;
77} ;
You can’t perform that action at this time.
0 commit comments