OfficeDev / OfficeDev/Office-Add-in-samples

Debugging Blazor Addin project

Open
#535 20 comments 0 reactions 1 assignee View on GitHub

@aafvstam is already working on this.

Since Jun 28, 2023.

Needs attention :wave: Needs: attention :wave:
Dominant language
JavaScript
Stars
1k
Forks
952
Avg merge
20h 36m
Merged PRs (30d)
32

Description

Debugging a project build on the "Blazor Addin" template gives me hard time.

  1. Break points for C# are not available for C# on the Blazor Addin templates, while you have them on any basic Blazor projects from "Visual Studio/create a project". It is a constraint but you can still get around using console.Writeline("").
  2. Break points for JS are available for JS. But
    - JS changes are randomly not updated (notably on an error but I cannot guarantee) :
    -- visual basic actually run the previous code
    -- breakpoints turn from red to yellow (not accessible) and sometimes disappear
    -- on some conditions (I didn't understand which!) a window named "localhost:7287 [dynamic] appears on the right side with the previous code; this window being readonly.
    - Afterward the project sticks on this previous JS code whatever you try : close the project, reboot machine, empty WEF or Bin folder, hit CTRL F5, activate debug for javascript ...
    - This behaviour expands to the other projects based on this same template that exists on your machine.
    - Changing the launchsettings applicationURL ( 7283, 7287, 7288 and 7289) gives you another try but inevitably you finish to
    spoil all these avalaible URL.
    - This behaviour desappears after hours or few days but I don't know whether it is spontaneous or due to tries I doing to solve it.

This behaviour seems to worsen with the size of the code.
Question
I am looking for any suggestion on how to handle this issue and

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.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.