You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to import Bootstrap Functions from an scss file. In my Vite config I have aliased "@" to the src directory, and I am trying to use the "@" alias when importing the scss file from node_modules. This has worked fine through Vite 5, but breaks in Vite 6 with the error [sass] Can't find stylesheet to import.
Open the reproduction link. Note that the app is failing with the error message [sass] Can't find stylesheet to import.
To see it working in Vite 5, in package.json change the Vite version to 5.4.11, and then in the terminal run npm install && npm run dev.
Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
Make sure this is a Vite issue and not a framework-specific issue. For example, if it's a Vue SFC related bug, it should likely be reported to vuejs/core instead.
It seems sass passes @/../node_modules/bootstrap/scss/_functions as node_modules/bootstrap/scss/_functions to Vite. This is a limitation of sass's modern API and there isn't a easy way to solve this.
Describe the bug
I am trying to import Bootstrap Functions from an scss file. In my Vite config I have aliased "@" to the src directory, and I am trying to use the "@" alias when importing the scss file from node_modules. This has worked fine through Vite 5, but breaks in Vite 6 with the error
[sass] Can't find stylesheet to import
.Reproduction
https://stackblitz.com/edit/vitejs-vite-y6lwlhpr?file=src%2Fstyle.scss
Steps to reproduce
Open the reproduction link. Note that the app is failing with the error message
[sass] Can't find stylesheet to import
.To see it working in Vite 5, in package.json change the Vite version to 5.4.11, and then in the terminal run
npm install && npm run dev
.System Info
Used Package Manager
npm
Logs
No response
Validations
The text was updated successfully, but these errors were encountered: