I am struggling to get sourcemaps working with css-loader.
Output in console:
What the documentation from css-loader says:
Sourc
Enable source-maps via webpack
...
devtool: 'source-map'
...
You might want to enable source-maps for Sass-Files as well
module: {
loaders: [
...
{
test: /\.scss$/,
loaders: [
'style-loader',
'css-loader?sourceMap',
'sass-loader?sourceMap'
]
}, {
test: /\.css$/,
loaders: [
"style-loader",
"css-loader?sourceMap"
]
},
...
]
}
Use extract text plugin to extract your css into a file.
...
plugins: [
...
new ExtractTextPlugin('file.css')
]
...