at-rule or selector expectedcss(css-ruleorselectorexpected)

738 Views Asked by At

When I try to build angular application and open the files in dist folder like index.html and try running these file on a live server it gives me this error

at-rule or selector expectedcss(css-ruleorselectorexpected)

specially on the lines contains

@charset "UTF-8"

here's a screenshot enter image description here

And also when I try to see what happen in the console it gives me different errors here's a screenshot enter image description here

1

There are 1 best solutions below

0
On

I've found an answer it's not a code error it's just the text editor doesn't accept this lines of code

@charset "UTF-8"

so to solve this just go to VSC settings->Extensions->CSS Language Feature->css and uncheck the css:Validate option