Getting Unexpected unknown at-rule "@use" in scss files

Hi,
I’ve just installed sonarcloud for our private repository.
It gives an error about something that’s not an error.
On a line in an scss file:
@use '@namespace/myPackage/myScssFile';
It gives the error:
Unexpected unknown at-rule "@use"
Any idea why this happens? How can I get rid of this false positive?

1 Like

Same issue here. Sonarqube handled SCSS specific @import properly, but as soon as I started switching to @use I got these false positives.

Hello,

we already have a ticket to track this request here https://github.com/SonarSource/sonar-css/issues/252. As a workaround you can configure S4662 rule with ignored at-rules to avoid FP.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.