Home >Backend Development >Golang >Why do I Get 'property value expected css' and 'at-rule or selector expected css' Errors When Using Go Templates in VSCode?
Troubleshooting "property value expected css" and "at-rule or selector expected css" Errors When Editing Go Templates in VSCode
When editing Go templates using the html/template package in VSCode, you may encounter errors such as "property value expected css" and "at-rule or selector expected css" when using {{ }} within the style attribute of HTML elements.
Solution:
The issue arises due to VSCode's HTML validation feature. To resolve this, you need to disable the HTML validate styles setting within VSCode.
[](/uploads/20241106/1730891500672b4eec09068.jpg)
After disabling HTML style validation, you should no longer encounter the "property value expected css" or "at-rule or selector expected css" errors when using {{ }} in the style attribute of HTML elements within Go templates.
The above is the detailed content of Why do I Get 'property value expected css' and 'at-rule or selector expected css' Errors When Using Go Templates in VSCode?. For more information, please follow other related articles on the PHP Chinese website!