Discussions

Ask a Question
Back to All

SourceMap for CSS?

Is it possible to generate a source map for CSS? I tried adding sourceMap: true, to the loader, but that didn't seem to do anything.

Unfortunately there is not at the moment. Getting it to work would take a very deep dive into webpack. The only code that I've seen that's able to accomplish it is the extract text webpack plugin, which I genuinely cannot understand at all despite having spent months diving in the webpack source code in order to build spike. Personally, I don't use source maps at all, so it just hasn't been worth it to me to continue the journey. However, if anyone else is interested in taking the lead on this, I'd be happy to help as much as I can!