/postcss-add-prefix

Primary LanguageJavaScriptMIT LicenseMIT

PostCSS Add Prefix

PostCSS plugin to add a prefix to all selectors

Without postcss-add-prefix

.first {
    display: block;
}

.first, .second {
    display: inline-block;
}

With postcss-add-prefix

.scope .first {
  display: block;
}

.scope .first, .scope .second {
  display: inline-block;
}

Usage

postcss([ require('postcss-add-prefix')( { selector: '.scope' } ) ])

Exclude

postcss([ require('postcss-add-prefix')( { selector: '.scope', exlude: ['modal*'] })])

No-prefix

@no-prefix;
.class {

}
@end-no-prefix;