Use sassc instead of node-sass
node-sass is a compiled ELF module, which is problematic for distributions that want to rebuild everything from source. The sassc CLI program is packaged everywhere, and both use the same libsass library. So drop node-sass and sass-loader, and replace it with a simple loader wrapper around sassc. This also saves 122 npm packages (16 MB in node_modules/). Closes #382
This commit is contained in:
parent
ea1377da1c
commit
233b5cfe04
4 changed files with 34 additions and 20 deletions
|
|
@ -118,6 +118,9 @@ module.exports = {
|
|||
resolve: {
|
||||
modules: [ nodedir ],
|
||||
},
|
||||
resolveLoader: {
|
||||
modules: [ nodedir, path.resolve(__dirname, 'src/lib') ],
|
||||
},
|
||||
watchOptions: {
|
||||
ignored: /node_modules/,
|
||||
},
|
||||
|
|
@ -165,15 +168,7 @@ module.exports = {
|
|||
]
|
||||
},
|
||||
},
|
||||
{
|
||||
loader: 'sass-loader',
|
||||
options: {
|
||||
sassOptions: {
|
||||
outputStyle: 'compressed',
|
||||
},
|
||||
sourceMap: true,
|
||||
},
|
||||
},
|
||||
'sassc-loader',
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
@ -188,15 +183,7 @@ module.exports = {
|
|||
url: false
|
||||
}
|
||||
},
|
||||
{
|
||||
loader: 'sass-loader',
|
||||
options: {
|
||||
sassOptions: {
|
||||
outputStyle: 'compressed',
|
||||
},
|
||||
sourceMap: true,
|
||||
},
|
||||
},
|
||||
'sassc-loader',
|
||||
]
|
||||
},
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue