Il talk ha come scopo raccontare come sia stato dapprima l'introduzione di strumenti di preprocessori come sass/less/stylus e in un secondo momento il passaggio a strumento di postproduzione del css come appunto postcss
19. POSTCSS
“PostCSS is a tool for transforming CSS with JS plugins.
These plugins can support variables and mixins, transpile
future CSS syntax, inline images, and more.”
20. POSTCSS NON È
COSA NON E’ POSTCSS
PREPROCESSOR
CSS FUTURE SYNTAX
POSTPROCESSOR
OPTIMIZATION TOOL
MINIFIER
PLUGIN JQUERY
ALL-IN-ONE TOOL
LINTER
SUBWAY SANDWICH
26. VELOCE
PostCSS: 39 ms
Rework: 73 ms (1.9 times slower)
libsass: 77 ms (1.9 times slower)
Less: 179 ms (4.5 times slower)
Stylus: 269 ms (6.8 times slower)
Stylecow: 271 ms (6.9 times slower)
Ruby Sass: 1101 ms (28.0 times slower)
34. I PLUGIN - BEM
@b nav { /* b is for block */
@e item { /* e is for element */
display: inline-block;
}
@m placement_header {
background-color: red;
}
}
.nav {}
.nav__item {
display: inline-block
}
.nav_placement_header {
background-color: red
}