fix: Remove usage of `DebuggerSupport` and `TrimmerRemoveSymbols` on release build
Arguably a bug report but using TrimmerRemoveSymbols makes it harder to debug things in release builds.
Symbols are usually trimmed to match the trimmed assemblies.
The default behavior should already include smaller symbols. By default .NET splits them (dll/exe + pdb only for symbols). With Portable PDBs they are already quite small. And can be published on snupkg packages and published to nuget.org. Debugger and other tools (such as sentry.io) can fetch the symbols from prod stack traces to add line numbers and file paths, as well as use source link to link to the original source code and fetch surrounding lines of code on stack traces. Source link info lives in the PDB.
So instead of removing symbols we can leave the default behavior, and publish a snupkg making the nupkg itself smaller while bugs easier to resolve.
Finally, using DebuggerSupport=false makes TrimmerRemoveSymbols redundant so we'd need to remove both ones:
https://github.com/microsoft/fluentui-blazor/blob/3b5c94354e4ca9ffc9cebcd794f3e1974db5e40e/src/Core/Microsoft.FluentUI.AspNetCore.Components.csproj#L40-L41
I'm happy to make the changes if we agree on this
Hello. Yes that could be a good idea. Could you also verify the SourceLink like describe here? https://www.meziantou.net/how-to-debug-nuget-packages-using-sourcelink.htm#test-sourcelink-is-e
Hi Bruno, would still love to get these changes in. You have some time soon to commit them?
Sorry I haven't had the time, if anyone wants to take this over please feel free, I don't want to block it
Ok, we will take it over.
Thank you!