close
The Wayback Machine - https://web.archive.org/web/20201023163058/https://github.com/angular/angular-cli/issues/18876
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ng serve does not generate service worker files #18876

Open
koenig-dominik opened this issue Sep 24, 2020 · 0 comments
Open

ng serve does not generate service worker files #18876

koenig-dominik opened this issue Sep 24, 2020 · 0 comments

Comments

@koenig-dominik
Copy link

@koenig-dominik koenig-dominik commented Sep 24, 2020

🚀 Feature request

Command (mark with an x)

  • new
  • build
  • serve
  • test
  • e2e
  • generate
  • add
  • update
  • lint
  • xi18n
  • run
  • config
  • help
  • version
  • doc

Description

A clear and concise description of the problem or missing capability...

The command ng serve currently does not generate service worker files.
It may be because in the past it was not possible to register service workers in non SSL sites.
There is now a exception to that, all http://localhost or http://127.x.y.z addresses do work (at least in Chrome)
This was already shortly discussed in #16883 (comment) but only the generation for ng build --watch was implemented.
ng serve & serve-ssr do not generate these files.

Describe the solution you'd like

If you have a solution in mind, please describe it.

Generate the needed service worker files in @angular-devkit/build-angular:dev-server & @nguniversal/builders:ssr-dev-server

Describe alternatives you've considered

Have you considered any alternative solutions or workarounds?

Build the universal server & run that without serve-ssr, which is really cumbersome in development

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.