-1๐
โ
I use the same stack. I have variables.scss
file with variables and bulma mixins and that variables.scss
file is imported only in main.scss
.
To make all variables and mixins available in all components without using @import
in style
section you should add loaderOptions
section to vue.config.js
file. Here is my vue.config.js
file:
module.exports = {
css: {
loaderOptions: {
scss: {
prependData: '@import "~@/assets/scss/_variables.scss";'
}
}
}
}
Source:stackexchange.com