-   Notifications  You must be signed in to change notification settings 
- Fork 26.7k
Closed
Labels
area: service-workerIssues related to the @angular/service-worker packageIssues related to the @angular/service-worker packagefreq1: lowtype: bug/fix
Milestone
Description
I'm submitting a...
 [ ] Regression (a behavior that used to work and stopped working in a new release) [x] Bug report [ ] Feature request [ ] Documentation issue or request [ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question Current behavior
The installation of a 2nd App/ServiceWorker (with different baseHref) purges the Cache Storage entries for a previously installed App/ServiceWorker, if they are on the same domain. This breaks the 1st installed App. It is not reachable anymore - you will always be redirected to the latest installed App.
Expected behavior
The installation of multiple Apps/ServiceWorkers (with different baseHref) on one domain should be possible.
Minimal reproduction of the problem with instructions
I created the following repo to reproduce the issue: https://github.com/skydever/repro-multiple-ng-apps-one-domain-serviceworker. Follow the steps of the README there.
What is the motivation / use case for changing the behavior?
I have to deploy multiple Angular Apps on one domain.
Environment
 Angular version: 5.1.3 Browser: - [x] Chrome (desktop) version XX - [ ] Chrome (Android) version XX - [ ] Chrome (iOS) version XX - [ ] Firefox version XX - [ ] Safari (desktop) version XX - [ ] Safari (iOS) version XX - [ ] IE version XX - [ ] Edge version XX For Tooling issues: - Node version: v8.9.1 - Platform: Windows Others: - http-server version 0.10.0
rrajewski, ronnymikalsen, jlbates, kctang, Splaktar and 8 more
Metadata
Metadata
Assignees
Labels
area: service-workerIssues related to the @angular/service-worker packageIssues related to the @angular/service-worker packagefreq1: lowtype: bug/fix