File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -130,9 +130,15 @@ var connection = new SockJS(url.format({
130
130
// Hardcoded in WebpackDevServer
131
131
pathname : '/sockjs-node'
132
132
} ) ) ;
133
- // Note: unlike WebpackDevServer's built-in client,
134
- // we don't handle disconnect. If connection fails,
135
- // just leave it instead of spamming the console.
133
+
134
+ // Unlike WebpackDevServer client, we won't try to reconnect
135
+ // to avoid spamming the console. Disconnect usually happens
136
+ // when developer stops the server.
137
+ connection . onclose = function ( ) {
138
+ console . info (
139
+ 'The development server has disconnected.\nRefresh the page if necessary.'
140
+ ) ;
141
+ } ;
136
142
137
143
// Remember some state related to hot module replacement.
138
144
var isFirstCompilation = true ;
You can’t perform that action at this time.
0 commit comments