-
Notifications
You must be signed in to change notification settings - Fork 464
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support 'compact' output style. #838
Comments
@davidangel, while this is a great idea, but you may want to consider using the alternative approach meanwhile. Since node.js is blessed with postcss a foundationally package, you can use packages like var postcss = require('postcss');
var csswring = require('csswring');
var nodeSass = require('node-sass');
var result = noseSass.renderSync({file: 'test.scss');
postcss().use(
csswring.postcss
).process(result.css); Or if you want to consume autoprefixer (yet another postcss based package which lets you configure various vendors' prefixes and autoprefix the output), it won't even require you to use csswring. See sass/node-sass#555 (comment) for example and this for full-scale node-sass example, which runs two postcss processors (Autoprefixer and RTLCss) on the node-sass output, while keeping the node-sass intact. Also, note that the most optimised and correct minification or CSS or JS is a very complicated and delicate matter. The most efficient CSS minifier IMO and in my experience is CSSO: https://github.com/css/csso (not sure whether they are postcss compatible). Therefore, for superset CSS languages, Scss, Less, Slylus etc., IMO it does not make much sense to at least "perfect" this aspect, for sake of separation of concerns. I think it would make sense to have a unified minification and source-mapping experience from all these post-processors, rather than the varied and yet fragmented one. (but most probably it is not applicable here, since libsass follows ruby-sass for feature selection) |
There's no right answer here, but this is certainly worth checking out. YMMV. https://github.com/GoalSmashers/css-minification-benchmark |
@xzyfer, interesting! I haven't tried |
👍 The options present in ruby-sass would be greatly appreciated. 😉 |
This should be solved by #910! |
Seeing pull request #910 ! Awesome work fellas! Thanks much! 👍 |
Cool! |
I think support for the 'compact' output is important to have. Especially since gulp-sass, and therefore nose-sass depends on libsass. The 'compact' output style is useful when trying to keep source maps correct when piping through other plugins.
Thanks.
The text was updated successfully, but these errors were encountered: