-
Notifications
You must be signed in to change notification settings - Fork 10.2k
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
Implement "attach" property support for Blazor debug extension #21716
Comments
The implementation for this will assume that a user has:
The requirements above are a mix of what our dev server needs and what the underlying JS debugger expects. The
Under the hood, this configuration will not spawn a process for the devserver and will launch the browser in attach mode. Unlike launch mode, |
A conversation with @SteveSandersonMS has me re-thinking this a bit. The interpretation of "attach" that I used above relies on a literal mapping of how attach currently works in the JS debug adapter. In actuality, a user using the "blazorwasm" debug adapter to "attach" probably intends to attach to a running Blazor WASM application, not a running debugging browser. This makes a lot more sense and is probably more useful to users than the model proposed above. Besides, if a user has already done the work to launch a browser in debug mode hooked to their application then the adapter isn't really providing much of an additional value to them (aside for hooking up their session to VS Code which 🤷) So really, the experience should be, you run |
@captainsafia That sounds good to me. I agree that the most useful "attach" gesture would be "open a new browser and attach it to an existing running app", rather than "attach the IDE to an existing browser+app pair". Could it be configurable? For example, if the launch settings options included a If making it configurable makes it really complicated then I'd be fine with only having the option to open a new browser (attaching to an existing app). |
We've got the flexibility to support both, it's largely a matter of how simple we want to keep the configuration to the end user. The debugging adapter we're releasing this week supports the |
This issue depends on the changes introduced in dotnet/razor#1885.
Currently, the Blazor debugger supports the
launch
property, meaning it starts a new dev server and browser from scratch.Launch configurations can also support an
attach
option. For example, the VS Code Chrome debug extension will attach to an existing browser (enabled with debugging) that is set to the same URL the user is targetting.The text was updated successfully, but these errors were encountered: