w3c / w3c/ServiceWorker

Add name param to Clients.openWindow() method

Open
#711 10 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

TPAC2025
Dominant language
Bikeshed
Stars
3.6k
Forks
324
Avg merge
14d 22h
Merged PRs (30d)
1

Description

OpenWindow creates a new window which can be accessed through the postMessage of the resulting Client object. It would be nice to add a 'name' param, like window.openWindow in order to allow the caller to communicate with the new window of the same domain using the 'name' instead of having to send a postMessage to the service worker and to the new clientWindow. In that way, we can get a reference to the new window opened in the service worker.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Clients.openWindow() entry point described in the issue, then compare it with the referenced window.openWindow behavior and the existing postMessage flow. Done means the API specification defines the requested name parameter and explains how callers can reference the newly opened same-origin window by name.

Written by the indexing model from the issue text.

Assessment

Domain
api
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.