@@ -111,9 +111,7 @@ export class DevServerBuilder implements Builder<DevServerBuilderOptions> {
111111 // Replace the assets in options with the normalized version.
112112 tap ( ( assetPatternObjects => browserOptions . assets = assetPatternObjects ) ) ,
113113 concatMap ( ( ) => new Observable ( obs => {
114- const browserBuilder = new BrowserBuilder ( this . context ) ;
115- const webpackConfig = browserBuilder . buildWebpackConfig (
116- root , projectRoot , host , browserOptions as NormalizedBrowserBuilderSchema ) ;
114+ const webpackConfig = this . buildWebpackConfig ( root , projectRoot , host , browserOptions ) ;
117115 const statsConfig = getWebpackStatsConfig ( browserOptions . verbose ) ;
118116
119117 let webpackDevServerConfig : WebpackDevServerConfigurationOptions ;
@@ -233,6 +231,19 @@ export class DevServerBuilder implements Builder<DevServerBuilderOptions> {
233231 } ) ) ) ;
234232 }
235233
234+ buildWebpackConfig (
235+ root : Path ,
236+ projectRoot : Path ,
237+ host : virtualFs . Host < fs . Stats > ,
238+ browserOptions : BrowserBuilderSchema ,
239+ ) {
240+ const browserBuilder = new BrowserBuilder ( this . context ) ;
241+ const webpackConfig = browserBuilder . buildWebpackConfig (
242+ root , projectRoot , host , browserOptions as NormalizedBrowserBuilderSchema ) ;
243+
244+ return webpackConfig ;
245+ }
246+
236247 private _buildServerConfig (
237248 root : Path ,
238249 projectRoot : Path ,
@@ -465,5 +476,4 @@ export class DevServerBuilder implements Builder<DevServerBuilderOptions> {
465476 }
466477}
467478
468-
469479export default DevServerBuilder ;
0 commit comments