PostCSS plugin for PagePlug px transform
npm install postcss-pageplug-pxtorem[PostCSS] plugin for PagePlug px transform.
[PostCSS]: https://github.com/postcss/postcss
``css`
.foo {
/ Input example /
}
`css`
.foo {
/ Output example /
}
Step 1: Install plugin:
`sh`
npm install --save-dev postcss postcss-pageplug-pxtorem
Step 2: Check you project for existed PostCSS config: postcss.config.js"postcss"
in the project root, section in package.jsonpostcss
or in bundle config.
If you do not use PostCSS, add it according to [official docs]
and set this plugin in settings.
Step 3: Add the plugin to plugins list:
`diff``
module.exports = {
plugins: [
+ require('postcss-pageplug-pxtorem'),
require('autoprefixer')
]
}
[official docs]: https://github.com/postcss/postcss#usage