Answer the question
In order to leave comments, you need to log in
What is postcss?
Google articles do not make it completely clear what PostCSS is. Everywhere they say that this is a miracle, but when asked what this library does, I answer - it does well.
If you do not give links to articles that you yourself have not read or read and did not understand, then what is PostCSS?
Why was it made when there is sass?
Answer the question
In order to leave comments, you need to log in
In order, for example, that you can write such a task in gulp, and that's cool
gulp.task('postcss', function () {
var processors = [
colorShort,
focus,
precss,
short,
size,
responsiveImages,
clearFix,
px2Rem,
cssNext,
cssMqpacker,
byeBye,
discardComments,
cssNano
];
return gulp.src('src/css/*.css')
.pipe(postcss(processors))
.pipe(gulp.dest('dist/css/'))
.pipe(browserSync.stream());
});
In short, it was invented for backwards compatibility with CSS. If in sass you need to use mixins to write prefixes (@include border-radius(10px)). Then using Postcss you do not need to write this. The Postcss authors think it's cool. You yourself connect what you need))))
In practice, I can say that I need mixins, variables and @extend. I can't work without it, as a result, I don't see a special need for Postcss. But Postcss is developing quite rapidly, you need to look after it, maybe something from this will turn out to be normal. If you use sass and use it, don't bother.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question