updated webpack-dev-server to accept a custom ssl certificate (#19996)

This commit is contained in:
Paul Colleoni
2017-10-02 10:35:24 -07:00
committed by Ryan Cavanaugh
parent 53d914345d
commit 2f07108478
2 changed files with 9 additions and 1 deletions
+2 -1
View File
@@ -8,12 +8,13 @@ import * as webpack from 'webpack';
import * as core from 'express-serve-static-core';
import * as serveStatic from 'serve-static';
import * as http from 'http';
import * as spdy from 'spdy';
declare namespace WebpackDevServer {
interface Configuration {
contentBase?: string;
hot?: boolean;
https?: boolean;
https?: boolean | spdy.ServerOptions;
historyApiFallback?: boolean;
compress?: boolean;
proxy?: any;
@@ -72,3 +72,10 @@ const config: WebpackDevServer.Configuration = {
// API example
server = new WebpackDevServer(compiler, config);
server.listen(8080, "localhost", () => {});
// HTTPS example
server = new WebpackDevServer(compiler, {
publicPath: "/assets/",
https: true
});
server.listen(8080, "localhost", () => {});