Comments (9)
@EAnushan thanks for the repo! I was able to reproduce this and can confirm this as an issue. Will publish a fix tomorrow in the AM (EST time zone here)
from gulp-clean-css.
I made some changes regarding path resolution in 2.2.2. I think you'll be okay if you remove what looks like a workaround to solve a defect in my earlier version. Specifically...
.write(undefined, {
sourceRoot: path.join(path.relative(options.css_min_dir, options.css_dir), path.sep)
}))
...looks like a code smell. I wrote a test to mock out the simple pipeline you provided and I can map back a sass'd and clean'd files to the originating sass. Could you try to modify what you have currently to see if it's fixed? I'd suggest the following...
.pipe(plugins.sourcemaps.write())
... without the pathing resolution passed. I could be way off, but I suspect it's at least worth trying! Thanks for bringing this to my attention. Also, if the issue persists, if you can create a sample replication repo with just a few files which illustrates the issue with your desired result I'll be able to get to the bottom of this much faster.
from gulp-clean-css.
I actually tried that fix as well, but it doesn't seem to help. I'll create a repo that reproduces the issue for you. Thanks for the quick response!
from gulp-clean-css.
cool keep me posted 😄
from gulp-clean-css.
Here's a proof of concept. Instructions in the README.
https://github.com/EAnushan/gulp-clean-css-issue-21
I've pushed a 2.1.1 branch that uses gulp-clean-css version 2.1.1 and doesn't have the same issue.
from gulp-clean-css.
hey guys I committed a possible fix here 06c1706. Could someone please clone this commit down, install, and verify? Probably a npm pack
=> install tarball would be the best bet. Didn't want to publish this quite yet if not fixed. Thanks
from gulp-clean-css.
Confirmed your last commit fixes the issue. I've also removed the sourceRoot
hack you mentioned in #21 (comment). Doesn't look like the hack is necessary anymore =)
from gulp-clean-css.
awesome, 2.3.0 pup'd
from gulp-clean-css.
Thank you!
from gulp-clean-css.
Related Issues (20)
- Error: Broken @import declaration .... - timeout HOT 1
- Minification should be optional HOT 5
- How to prevent rebase of images in css? HOT 2
- clean-css => 4.2.1 HOT 2
- @import not coming in minified css HOT 2
- @import url('') deleted when minifying HOT 4
- file.contents.toString() throws exception after 4.x release HOT 19
- Relative paths to a picture in selects: after and: before HOT 3
- Quotes removed from single column grid definitions HOT 1
- Can't find options to generate a .min file HOT 1
- CI build missing Node 12 etc. HOT 2
- Options object can't be used multiple times
- Valid CSS be cleaned HOT 1
- Errors in CleanCSS cause abort with no diagnostics.
- Consider aborting on errors after calling user-supplied callback.
- Callback not running
- the compatability option is not working
- Upgrade gulp-clean-css to match clean-css version 5.* HOT 3
- problem with css cascade laayers
- Not compatible with SASS?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gulp-clean-css.