postcss-simple-scope

1.0.0 • Public • Published

postcss-simple-scope

Input

body {
  background: red;
}

.header {
  background: black;
}

Output

body {
  background: red;
}

#scope .header {
  background: black;
}

Usage

npm i -D postcss-simple-scope
// .postcssrs.cjs
module.exports = {
  plugins: [
    require('postcss-simple-scope')({
      scope: '#scope', // required
      atRules: {
        exclude: ['keyframes', '-webkit-keyframes', '-moz-keyframes'], // default
      }, // optional
      selectors: {
        exclude: [':root', '*', 'html', 'body'], // default
      }, // optional
    }),
  ],
};

/postcss-simple-scope/

    Package Sidebar

    Install

    npm i postcss-simple-scope

    Weekly Downloads

    1

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    2.31 kB

    Total Files

    3

    Last publish

    Collaborators

    • brantem