Subscribe on changes!

scss @import from 'node_modules' is not working for CustomElements

avatar
Aug 27th 2021

Version

3.2.6

Reproduction link

https://github.com/sawden/vue-custom-element-scss-import-bug

Steps to reproduce

  • Clone the reproduction repository
  • npm i
  • npm run serve

What is expected?

The neon-btn.css in src/components/ExampleButton/ExampleButton.scss is imported and the styles are visible in the shadow-root.

What is actually happening?

The styles are not imported and the @import "~neon-button-css/neon-btn.css"; statement is directly rendered to the shadow-root styles.

shadow-root-screenshot