Skip to content

Replace pageIdx with pageIds #688

@OrKoN

Description

@OrKoN

Is your feature request related to a problem? Please describe.

To provide stable ids for pages and enable interoperability with other tools, we propose replacing pageIdx with pageId based on the CDP's tab target ID.

With the Multiple Page Architecture in Chromium https://docs.google.com/document/d/1NginQ8k0w3znuwTiJ5qjYmBKgZDekvEPC22q0I4swxQ/edit?tab=t.0#heading=h.w1qo2n6sr8wn a single tab might host multiple page targets. Page targets are parented under a tab target that can be used to handle page activations.

Puppeteer's page API sits on top of the tab target meaning Puppeteer handles page activations for us. Therefore, the tab target seems like the best ID to use here.

Describe the solution you'd like

Using tab target IDs as a pageId.

Describe alternatives you've considered

  • Using page target ID as a pageId.
  • Creating a custom page ID.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions