title: Service worker registration failed with: TypeError: Failed to register a ServiceWorker for scope
body: <p>I am having a problem with registering service worker in my angular app. Everything was working fine, before I switched from standard npm run start script:</p>
  <pre><code>&quot;start&quot;: &quot;ng serve --aot --port 4200&quot;
  </code></pre>
  <p>to script using specific configuration, where I just replace my assets, styles and scripts and environment files.</p>
  <pre><code>&quot;start&quot;: ng serve --aot --configuration=development --port 4200
  </code></pre>
  <p>My question is, what is the standard configuration for ng serve, so I could configure my configuration in a similar way? Or if the problem lies somewhere else, what could I do to fix it? How can I disable service worker on a development environment? serviceWorker: false in angular json does not work. (I am still getting errors)</p>