Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow scoping devtools to a particular frame #129437

Closed
deepak1556 opened this issue Jul 26, 2021 · 8 comments
Closed

Allow scoping devtools to a particular frame #129437

deepak1556 opened this issue Jul 26, 2021 · 8 comments
Assignees
Labels
*as-designed Described behavior is as designed debt Code quality issues engineering VS Code - Build / issue tracking / etc.

Comments

@deepak1556
Copy link
Contributor

Extracted from lostintangent/codeswing#50

With OOPIF webview, extensions don't have a way to scope the top-level devtools to the frame. Can electron hook into content::RenderFrameDevToolsAgentHost to fix this ?

Issue is mostly to experiment with above idea.

@deepak1556 deepak1556 self-assigned this Jul 26, 2021
@deepak1556 deepak1556 added debt Code quality issues engineering VS Code - Build / issue tracking / etc. labels Jul 26, 2021
@deepak1556 deepak1556 added this to the August 2021 milestone Jul 26, 2021
@rzhao271 rzhao271 self-assigned this Aug 4, 2021
@bpasero bpasero moved this from New to To do in Electron Integration Aug 9, 2021
@rzhao271
Copy link
Contributor

So far, to pass in the agent host for content::RenderFrameDevToolsAgentHost, I tried creating one with RenderFrameDevToolsAgentHost::GetFor https://source.chromium.org/chromium/chromium/src/+/main:content/browser/devtools/render_frame_devtools_agent_host.cc;l=388;drc=f0831f26cd194c819e0f3aa5920fdd88c8d2380e, but that returns nullptr.
I'll try some of the other functions in that file that look more promising, such as RenderFrameDevToolsAgentHost::GetOrCreateFor, tomorrow.

@deepak1556
Copy link
Contributor Author

@Tyriar @eamodio if Toggle Webview developer tools action were to restore the old behavior, would Toggle Developer Tools action suffice for your use case or do you need a separate action to keep today's webview devtools behavior ?

@Tyriar
Copy link
Member

Tyriar commented Aug 11, 2021

@deepak1556 Toggle Developer Tools is what I use today, as long as the webviews are included in there that's good for me as devtools stays open across reloads.

Here is the issue I created that explains the problem I had with toggle webview developer tools #118919

@deepak1556
Copy link
Contributor Author

Toggle Developer Tools is what I use today, as long as the webviews are included in there that's good for me as devtools stays open across reloads.

Yup this will continue to work.

@rzhao271 rzhao271 moved this from To do to In progress in Electron Integration Aug 11, 2021
@deepak1556
Copy link
Contributor Author

/cc @mjbvz

Originally extracted from lostintangent/codeswing#50

@mjbvz
Copy link
Contributor

mjbvz commented Aug 12, 2021

Using our standard editor developer tools for webviews has a few advantages:

  • You can inspect multiple webviews at the same time
  • You don't have to manage multiple windows
  • You can view console logs from the extension and the webview in the same location

Besides this issue, I haven't seen any other feedback requesting the old webview developer experience. We perviously used multiple dev tools because that was the only option when using <webview> tags, but I'm not sure it makes sense to try brining them back

@deepak1556
Copy link
Contributor Author

Thanks for the feedback, closing for now.

@mjbvz can you please engage in lostintangent/codeswing#50

@bpasero bpasero moved this from In progress to Done / Deferred in Electron Integration Aug 16, 2021
@rzhao271 rzhao271 removed this from the August 2021 milestone Aug 23, 2021
@rzhao271 rzhao271 added the *as-designed Described behavior is as designed label Aug 23, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Sep 26, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*as-designed Described behavior is as designed debt Code quality issues engineering VS Code - Build / issue tracking / etc.
Projects
Archived in project
Electron Integration
  
✔️ Done / Deferred
Development

No branches or pull requests

4 participants