ODBRM 2020-04-17 19:31 采纳率: 0%
浏览 3122
已采纳

Uni-app sass无法编译成css,sass-loader错误

winodws平台下的uni-app项目,在使用了sass后模块无法加载,换成HbuilderX安装插件也不能运行。
求救!

19:20:36.861 Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
19:20:36.862 ModuleBuildError: Module build failed (from ./node_modules/sass-loader/dist/cjs.js):
19:20:36.875 SassError: Invalid argument(s): Unsupported output style "nested".
19:20:36.876     at runLoaders (C:\Users\WI\Downloads\HBuilderX\plugins\uniapp-cli\node_modules\webpack\lib\NormalModule.js:301:20)
19:20:36.890     at C:\Users\WI\Downloads\HBuilderX\plugins\uniapp-cli\node_modules\loader-runner\lib\LoaderRunner.js:367:11
19:20:36.890     at C:\Users\WI\Downloads\HBuilderX\plugins\uniapp-cli\node_modules\loader-runner\lib\LoaderRunner.js:233:18
19:20:36.900     at context.callback (C:\Users\WI\Downloads\HBuilderX\plugins\uniapp-cli\node_modules\loader-runner\lib\LoaderRunner.js:111:13)
19:20:36.900     at render (C:\Users\WI\Downloads\HBuilderX\plugins\uniapp-cli\node_modules\sass-loader\dist\index.js:73:7)
19:20:36.914     at Function.call$2 (C:\Users\WI\node_modules\sass\sass.dart.js:54311:16)
19:20:36.915     at _render_closure1.call$2 (C:\Users\WI\node_modules\sass\sass.dart.js:33511:12)
19:20:36.933     at _RootZone.runBinary$3$3 (C:\Users\WI\node_modules\sass\sass.dart.js:19817:18)
19:20:36.934     at _RootZone.runBinary$3 (C:\Users\WI\node_modules\sass\sass.dart.js:19821:19)
19:20:36.955     at _FutureListener.handleError$1 (C:\Users\WI\node_modules\sass\sass.dart.js:18286:19)
19:20:36.956     at _Future__propagateToListeners_handleError.call$0 (C:\Users\WI\node_modules\sass\sass.dart.js:18574:40)
19:20:36.970     at Object._Future__propagateToListeners (C:\Users\WI\node_modules\sass\sass.dart.js:3484:88)
19:20:36.971     at _Future._completeError$2 (C:\Users\WI\node_modules\sass\sass.dart.js:18410:9)
19:20:36.990     at _Future__asyncCompleteError_closure.call$0 (C:\Users\WI\node_modules\sass\sass.dart.js:18500:18)
19:20:36.990     at Object._microtaskLoop (C:\Users\WI\node_modules\sass\sass.dart.js:3534:21)
19:20:37.009     at StaticClosure._startMicrotaskLoop (C:\Users\WI\node_modules\sass\sass.dart.js:3540:11)
19:20:37.010  ERROR  Build failed with errors.
  • 写回答

3条回答 默认 最新

  • Nancy_959 2020-04-23 16:16
    关注

    sass模块经常下的时候回出错
    npm install node-sass --save-dev
    npm install sass-loader --save-dev
    这两个模块都要装,如果还是不行,试试用cnpm装

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(2条)

报告相同问题?

悬赏问题

  • ¥15 素材场景中光线烘焙后灯光失效
  • ¥15 请教一下各位,为什么我这个没有实现模拟点击
  • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
  • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
  • ¥15 ubuntu子系统密码忘记
  • ¥15 保护模式-系统加载-段寄存器