@@ -436,14 +436,12 @@ export class DevServerBuilder implements Builder<DevServerBuilderOptions> {
436
436
private _getBrowserOptions ( options : DevServerBuilderOptions ) {
437
437
const architect = this . context . architect ;
438
438
const [ project , target , configuration ] = options . browserTarget . split ( ':' ) ;
439
- // Override browser build watch setting.
440
- const overrides = { watch : options . watch } ;
441
- const browserTargetSpec = { project, target, configuration, overrides } ;
442
- const builderConfig = architect . getBuilderConfiguration < BrowserBuilderSchema > (
443
- browserTargetSpec ) ;
444
439
445
- // Update the browser options with the same options we support in serve, if defined.
446
- builderConfig . options = {
440
+ const overrides = {
441
+ // Override browser build watch setting.
442
+ watch : options . watch ,
443
+
444
+ // Update the browser options with the same options we support in serve, if defined.
447
445
...( options . optimization !== undefined ? { optimization : options . optimization } : { } ) ,
448
446
...( options . aot !== undefined ? { aot : options . aot } : { } ) ,
449
447
...( options . sourceMap !== undefined ? { sourceMap : options . sourceMap } : { } ) ,
@@ -453,10 +451,12 @@ export class DevServerBuilder implements Builder<DevServerBuilderOptions> {
453
451
...( options . baseHref !== undefined ? { baseHref : options . baseHref } : { } ) ,
454
452
...( options . progress !== undefined ? { progress : options . progress } : { } ) ,
455
453
...( options . poll !== undefined ? { poll : options . poll } : { } ) ,
456
-
457
- ...builderConfig . options ,
458
454
} ;
459
455
456
+ const browserTargetSpec = { project, target, configuration, overrides } ;
457
+ const builderConfig = architect . getBuilderConfiguration < BrowserBuilderSchema > (
458
+ browserTargetSpec ) ;
459
+
460
460
return architect . getBuilderDescription ( builderConfig ) . pipe (
461
461
concatMap ( browserDescription =>
462
462
architect . validateBuilderOptions ( builderConfig , browserDescription ) ) ,
0 commit comments