nuxt-modules / stylelint

Stylelint module for Nuxt.js
MIT License
65 stars 9 forks source link

Error - Unknown word `lang="scss"` #87

Closed legostud closed 1 year ago

legostud commented 1 year ago

I just installed this package for my Nuxt 3 project and it's throwing errors that I'm not sure how to resolve.

"components/field/RichText.vue 8:10 ✖ Unknown word CssSyntaxError"

I was able to resolve the error by removing the lang="scss" attribute from my style tag, but I need that in order to write SCSS. Is there a way to have Stylelint ignore that attribute?

<style lang="scss" scoped>
.rich-text-field {
  font-family: var(--f-primary);
  font-size: var(--rich-text-font-size, 1rem);
  max-width: var(--l-max-width-rte);
  margin-inline: var(--l-rte-margins, 0);
}
</style>

stylelint-error.zip

legostud commented 1 year ago

I think this is something to do with my stylelintrc file. I've added stylelint-config-recommended-vue and it seems to be working better.