babel-plugin-csjs-postcss

0.3.0 • Public • Published

babel-plugin-csjs-postcss

build status dependencies status

Babel plugin for running PostCSS on CSJS at build time

Autoprefixer example

npm i babel-plugin-csjs-postcss autoprefixer --save-dev

Before:

csjs`

.foo {
  transform: ${foo};
}

`;

After:

csjs`

.foo {
  -webkit-transform: ${ foo };
          transform: ${ foo };
}

`;

.babelrc

{
  "plugins": [["csjs-postcss", {
    "plugins": ["autoprefixer"]
  }]]
}

Advanced Configuration

.babelrc

{
  "plugins": [["csjs-postcss", {
    "plugins": [["autoprefixer", {"browsers": ["last 2 versions"]}]]
  }]]
}

Readme

Keywords

Package Sidebar

Install

npm i babel-plugin-csjs-postcss

Weekly Downloads

33

Version

0.3.0

License

MIT

Last publish

Collaborators

  • rtsao