Skip to content

Commit b2262e9

Browse files
Alan Agiusvikerman
Alan Agius
authored andcommitted
fix(@angular-devkit/build-angular): live reload cannot be disabled
By default the application will be served with inline mode enabled. This means that a script will be inserted in your bundle to take care of live reloading. However at the moment we are already adding these scripts in `_addLiveReload` method. With this change we always disable this behaviour and only add it when needed via the `_addLiveReload` logic. Eventually we should try to remove the logic and rely on webpack-dev-server interals. Fixes #14300
1 parent 29609fb commit b2262e9

File tree

1 file changed

+2
-0
lines changed
  • packages/angular_devkit/build_angular/src/dev-server

1 file changed

+2
-0
lines changed

packages/angular_devkit/build_angular/src/dev-server/index.ts

+2
Original file line numberDiff line numberDiff line change
@@ -274,6 +274,8 @@ export function buildServerConfig(
274274
errors: !(styles || scripts),
275275
warnings: false,
276276
},
277+
// inline is always false, because we add live reloading scripts in _addLiveReload when needed
278+
inline: false,
277279
public: serverOptions.publicHost,
278280
disableHostCheck: serverOptions.disableHostCheck,
279281
publicPath: servePath,

0 commit comments

Comments
 (0)