Coming soon - Get a detailed view of why an account is flagged as spam!
view details

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

0
A little help with Webpack and Sass?
Post Body

So, I've been tearing my hair out over this problem with Webpack generating incorrect sourcemaps for my Sass files. When I inspect in developer tools (or use a tool like this one), the generated CSS maps to the wrong source files. This only seems to happen with my own code, not third-party Sass files (I'm including Bootstrap in my project). I've definitely narrowed the issue down to being Webpack-related: When I compile from the command line with (Dart) Sass, the emitted sourcemap is correct. I've setup an example project to prove this. The Webpack configuration there is nearly identical to my actual project's config (except the actual project's config also compiles JS, images, fonts, etc.). Compare the output in the dist directory when you run npm run build to when you run sass --embed-sources -I ./node_modules/ src/scss/app.scss:dist/app.css, there's definitely a difference in the main sourcemap. If it matters, you'll notice that I'm using use directives instead of import (as opposed to Bootstrap's outdated Sass code).

Author
Account Strength
100%
Account Age
7 years
Verified Email
Yes
Verified Flair
No
Total Karma
5,125
Link Karma
983
Comment Karma
4,129
Profile updated: 3 days ago
Posts updated: 8 hours ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
1 month ago