We want to make use of the SonarQube for IDE plugin in Rider. Our main project is a .NET Blazor Web Assembly project containing a lot of .razor files. We have noted that .razor files used to be unsupported, but some two years ago, support was added. We are able to see issues in the SonarQube Web Portal in our .razor files, but we would like to see them in our IDE too, something which just is not working at all
The plugin works well for .cs files but for .razor files it does not automatically analyze, nor does the manual analyze button do anything when clicking it with a .razor file open. The Debug log also does not produce any output when trying to analyze .razor files.
In the log we see sonar.cs.analyzeRazorCode=true and I have also desperately added .razor files to the C# suffix list in our project settings but with no change.
We indeed somewhat recently added support for analyzing razor files in our analyzer. However, because of a bug in the Roslyn compiler, it only worked for a full analysis (i.e., not in the IDE).
The bug has since been corrected, and we are currently implementing Razor analysis in SonarQube for IDE. Unfortunately, we discovered Rider itself suppresses issues on these files, so we will not be able to implement it for this IDE at this time (do not hesitate to upvote and comment on that Rider issue, it might help push JetBrains to do something about it).
We will deliver Razor analysis in SonarQube for IDE: Visual Studio in the next version. We are considering implementing it for SonarQube for IDE: Visual Studio Code.
We will be eagerly awaiting the VS update as we can also use VS for local analysis as a workaround. I hope there will be progress for Jetbrains in the near future, allowing the analysis to be worked on there too