File tree 2 files changed +10
-3
lines changed
2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ var express = require("express");
5
5
var compress = require ( "compression" ) ;
6
6
var sockjs = require ( "sockjs" ) ;
7
7
var http = require ( "http" ) ;
8
- var https = require ( "https " ) ;
8
+ var spdy = require ( "spdy " ) ;
9
9
var httpProxyMiddleware = require ( "http-proxy-middleware" ) ;
10
10
var serveIndex = require ( "serve-index" ) ;
11
11
var historyApiFallback = require ( "connect-history-api-fallback" ) ;
@@ -307,7 +307,13 @@ function Server(compiler, options) {
307
307
options . https . cert = options . https . cert || fs . readFileSync ( path . join ( __dirname , "../ssl/server.crt" ) ) ;
308
308
options . https . ca = options . https . ca || fs . readFileSync ( path . join ( __dirname , "../ssl/ca.pem" ) ) ;
309
309
310
- this . listeningApp = https . createServer ( options . https , app ) ;
310
+ if ( ! options . https . spdy ) {
311
+ options . https . spdy = {
312
+ protocols : [ "h2" , "http/1.1" ]
313
+ } ;
314
+ }
315
+
316
+ this . listeningApp = spdy . createServer ( options . https , app ) ;
311
317
} else {
312
318
this . listeningApp = http . createServer ( app ) ;
313
319
}
Original file line number Diff line number Diff line change 13
13
"http-proxy-middleware" : " ~0.17.1" ,
14
14
"opn" : " 4.0.2" ,
15
15
"serve-index" : " ^1.7.2" ,
16
- "sockjs" : " 0.3.17 " ,
16
+ "sockjs" : " 0.3.18 " ,
17
17
"sockjs-client" : " 1.1.1" ,
18
+ "spdy" : " ^3.4.1" ,
18
19
"strip-ansi" : " ^3.0.0" ,
19
20
"supports-color" : " ^3.1.1" ,
20
21
"webpack-dev-middleware" : " ^1.4.0" ,
You can’t perform that action at this time.
0 commit comments