Created
May 9, 2016 16:25
-
-
Save i-like-robots/f36573e9f6afae1b12213cfecd7cd319 to your computer and use it in GitHub Desktop.
Minimum Webpack config to output separate stylesheets with sourcemaps
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict' | |
const ExtractTextPlugin = require('extract-text-webpack-plugin') | |
module.exports = { | |
entry: { | |
'./public/main.css': './src/styles.scss' | |
}, | |
output: { | |
filename: '[name]' | |
}, | |
module: { | |
loaders: [ | |
{ | |
test: /\.scss$/, | |
loader: ExtractTextPlugin.extract('style', ['css?sourceMap', 'sass?sourceMap']) | |
} | |
] | |
}, | |
devtool: 'source-map', | |
plugins: [ | |
new ExtractTextPlugin('[name]') | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment