.vue suffix needed for SonarHTML and SonarCSS?

Hello! Recently both the SonarCSS and SonarHTML plugins have added support (such as https://jira.sonarsource.com/browse/SONARHTML-83) for Vue.js Single File Components (.vue files). My question is, do I need to manually add “.vue” to sonar.css.file.suffixes and sonar.html.file.suffixes in order for that to work? I see sonar.javascript.file.suffixes has it added (by default), so if they’re consistent then my guess is yes.

Thanks!

-Matthew

Hi,

No, you don’t need to add .vue to other languages extensions (it will make analysis fail as each extension should be unique).
And unfortunately SonarCSS does not analyse .vue files (only HTML and PHP), while we might consider adding its support in future.

Thanks! I’m a bit confused by your SonarCSS comment though, the release notes for SonarCSS v1.1 explicitly call out that support (as part of https://github.com/SonarSource/sonar-css/issues/86).

Indeed it’s confusing, our bad. In fact that feature was added during development but we had to disable it in bug-fix release (https://github.com/SonarSource/sonar-css/pull/188) due to a problem with JSX.

1 Like

Gotcha, thanks!