postcss-critical-split
Version:
A PostCSS plugin that takes existing CSS files and splits out the annotated critical styles into a seperate file.
33 lines (25 loc) • 330 B
CSS
body {
background-color: black;
}
p {
color: red;
}
a {
text-decoration: none;
}
@media screen and (min-width: 400px) {
a {
color: #ff0;
border-bottom: 1px solid #ff0;
/* critical */
}
}
@media screen and (min-width: 450px) {
strong {
transform: scale(200%);
}
}
h1 {
font-size: 3em;
font-weight: bold;
}