Sass loader to scope styles inside selector
This plugin scopes all your styles inside a configurable selector:
//Before sass-scope-loader
.input {
//...
}
//After sass-scope-loader width options.selector ".my-plugin"
.my-plugin .input {
//...
}
npm install --save sass-scope-loader
/* webpack.config.js */
module.exports = {
module: {
rules: [
{
test: /\.scss$/,
use: {
loader: 'sass-scope-loader',
options: {
selector: '.SCOPESELECTOR',
},
},
},
],
},
}
The MIT License Copyright (c) Carsten Jacobsen