should getRegistration() return anything for clients with a local URL that inherited the controller?
Nobody has claimed this yet.
- Dominant language
- Bikeshed
- Stars
- 3.6k
- Forks
- 324
- Avg merge
- 14d 22h
- Merged PRs (30d)
- 1
Description
The ServiceWorkerContainer.getRegistration() method takes a URL, but allows it to default to the empty string. Since the value is used to resolve a URL with the client's base URL, this effectively does a getRegistration() with the client's base URL.
Should this be expected to work for clients with a local URL (about:blank, blob:, etc) that are controlled by a service worker (thanks to inheritance)? In these cases it seems a getRegistration() with the default arg will try to find a scope matching the local URL which should always fail.
It seems like the default arg form of getRegistration() is often used to get the registration for the controlling service worker. Should we try to support this use case for these local URL clients?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the ServiceWorkerContainer.getRegistration() entry point and its URL-resolution behavior for clients using about:blank or blob: URLs. Review how inherited service-worker control is described for local URL clients, then determine whether the specification needs a clear resolution; done means the expected behavior and any required specification change are agreed.
Written by the indexing model from the issue text.
Assessment
- Domain
- api, web-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100