MicrosoftEdge / MicrosoftEdge/WebView2Feedback

[Feature]: Pass Uri and FrameId into Frame::NavigationCompleted and NavigationStarted event handler

Open
#4,604 1 comment 0 reactions 1 assignee View on GitHub

@Lakshmisha-KS is already working on this.

Since Feb 12, 2025.

feature request tracked
Dominant language
PowerShell
Stars
526
Forks
67
PR merge metrics
No merged PRs in 30d

Description

Describe the feature/enhancement you need

I want to access the FrameId inside of the CoreWebView2::FrameNavigationCompleted or Frame::NavigationCompleted events as well as FrameNavigationStarting. See all the info here that Electron passes in a similar event.

NavStarting args have Uri but not FrameId

Also to DomContentLoaded - frameID would be useful here for me.

The scenario/use case where you would use this feature

Need to detect when a frame navigates and see what frame it was. Similar to this request (which is also helpful to me) where they suggest passing the Uri property in.

I'm currently having to intercept FrameCreated and then Frame::NavigationStarting and save off e.Uri in some map, keyed by e.NavigationId, and then pull it out in Frame::NavigationCompleted

How important is this request to you?

Nice to have. There are other ways to tackle this, but having official API support would be beneficial.

Suggested implementation

pass info that Electron passes in like uri, frameId. (they have two different frameIds, maybe both make sense to pas? not sure)

What does your app do? Is there a pending deadline for this request?

No response

AB#53262297

Contributor guide

No contributing guide indexed for this repository

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.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.