使用uView-ui 并且安装了scss/sass编译插件的情况下,scss for语法报错
16:29:39.562 Module build failed (from ./node_modules/postcss-loader/src/index.js):  
16:29:39.563 SyntaxError  
16:29:39.569 (113:12) Unknown word  
16:29:39.569   111 | // 定义flex等分  
16:29:39.575   112 | @for $i from 0 through 12 {  
16:29:39.576 > 113 |    .u-flex-#{$i} {  
16:29:39.580       |              ^  
16:29:39.580   114 |        flex: $i;  
16:29:39.585   115 |    } 
             
             
             
			 
                                        
                                     
            
3 个回复
2***@qq.com
请问解决了吗
5***@qq.com
在App.vue中首行的位置引入,注意给style标签加入lang="scss"属性
1***@qq.com
太感谢了
2021-07-14 11:06
3***@qq.com
如果是组件里面引入的,看下style 标签有没有设置 lang="scss"。