Code analysis for C# AND JavaScript

We are trying to get SonarCloud integrated into one of our Visual Studio solutions through an Azure DevOps pipeline. This solution has multiple .NET Core projects with C#/.NET code and it also contains a frontend SPA developed using languages such as PL/SQL, JavaScript/TypeScript, CSS and HTML.

We are struggling to get code analysis of the entire codebase reported to the SonarCloud project.

When we set up a SonarCloudPrepare@1 step with scannerMode set to ‘MSBuild’ it doesn’t report any frontend SPA code scanning results.

When we set up a SonarCloudPrepare@1 step with scannerMode set to ‘CLI’ it doesn’t report any C#/.NET code scanning results.

I’m just wondering if anyone managed to get both C#/.NET and JavaScript code analysis reported into a single SonarCloud project via an Azure DevOps pipeline…

Many Thanks,

Dilan Perera.

Hey there.

Take a look at these docs.

Thanks, Colin! highly appreciated…

Meanwhile, I found the following answer with a code example and my issue is now resolved.

Cheers,

Dilan.

1 Like