'why the scss file need different type of loader
Now I read the config that package the scss file write like this:
{
test: /\.css$/i,
use: [MiniCssExtractPlugin.loader, "css-loader"],
},
{
test : /\.(scss)$/ ,
use: [
MiniCssExtractPlugin.loader,
{
loader: "css-loader",
options: {
modules: true,
sourceMap: true
}
},
"sass-loader"
]
}
why the scss file need 3 type of loader? what is the parse process? first using MiniCssExtractPlugin.loader then css-loader and finnally sass-loader? why did not using the only one sass-loader to parse the scss file?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
