File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed
packages/server/server/src/dev-tools/dev-middleware/hmr-client Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ ' @modern-js/server ' : patch
3+ ---
4+
5+ fix(dev-server): adjust hmr connection log level
6+
7+ fix(dev-server): 调整 hmr 连接的日志级别
Original file line number Diff line number Diff line change @@ -28,9 +28,9 @@ const socketUrl = createSocketUrl(__resourceQuery);
2828const connection = new WebSocket ( socketUrl ) ;
2929
3030connection . onopen = function ( ) {
31- if ( typeof console !== 'undefined' && typeof console . debug === 'function' ) {
31+ if ( typeof console !== 'undefined' && typeof console . info === 'function' ) {
3232 // Notify users that the HMR has successfully connected.
33- console . debug ( '[HMR] connected.' ) ;
33+ console . info ( '[HMR] connected.' ) ;
3434 }
3535} ;
3636
@@ -39,7 +39,7 @@ connection.onopen = function () {
3939// when developer stops the server.
4040connection . onclose = function ( ) {
4141 if ( typeof console !== 'undefined' && typeof console . info === 'function' ) {
42- console . debug ( '[HMR] disconnected. Refresh the page if necessary.' ) ;
42+ console . info ( '[HMR] disconnected. Refresh the page if necessary.' ) ;
4343 }
4444} ;
4545
You can’t perform that action at this time.
0 commit comments