what does sass loader do code example
Example 1: sass node sass loder
npm install sass-loader node-sass webpack --save-dev
Example 2: mini-css-extract-plugin sass
//installation
npm install --save-dev mini-css-extract-plugin
//configuration
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
module.exports = {
plugins: [new MiniCssExtractPlugin()],
module: {
rules: [
{
test: /\.css$/i,
use: [MiniCssExtractPlugin.loader, 'css-loader'],
},
],
},
};
Example 3: sass loader
yarn add -D sass-loader