查找自己webpack版本对应sass-loader
查看webpack版本
npm list webpack
sass-loader v7.x对应webpack v4.x
sass-loader v8.x对应webpack v4.x或v5.x
sass-loader v9.x对应webpack v4.x或v5.x或v6.x
sass-loader v10.x对应webpack v5.x或v6.x或v7.x
安装对应版本
npm install sass-loader@X --save-dev
npm install sass --save-dev