File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -205,7 +205,9 @@ function onClose() {
205205 return ;
206206 }
207207
208- console . info ( '[rsbuild] WebSocket connection lost. Reconnecting...' ) ;
208+ if ( reconnectCount === 0 ) {
209+ console . info ( '[rsbuild] WebSocket connection lost. Reconnecting...' ) ;
210+ }
209211 removeListeners ( ) ;
210212 socket = null ;
211213 reconnectCount ++ ;
@@ -225,7 +227,10 @@ function onError() {
225227
226228// Establishing a WebSocket connection with the server.
227229function connect ( fallback = false ) {
228- console . info ( '[rsbuild] WebSocket connecting...' ) ;
230+ if ( reconnectCount === 0 ) {
231+ console . info ( '[rsbuild] WebSocket connecting...' ) ;
232+ }
233+
229234 const socketUrl = formatURL ( fallback ) ;
230235 socket = new WebSocket ( socketUrl ) ;
231236 socket . addEventListener ( 'open' , onOpen ) ;
You can’t perform that action at this time.
0 commit comments