Sass loader not working in webpack

后端 未结 3 1000
一向
一向 2021-02-07 02:56

I am trying to get *.scss files to be supported in my webpack configuration but I keep getting the following error when I run the webpack build command:

ERROR in         


        
3条回答
  •  有刺的猬
    2021-02-07 03:57

    After having the same issue, I found this: https://github.com/webpack/css-loader/issues/84

    Apparently, the solution for now is to manually modify lines 17-19 of /node_modules/css-loader/lib/loader.js with

    if(map && typeof map !== "string") {
        map = JSON.stringify(map);
    }
    

    This fixed the problem for me.

提交回复
热议问题