hoo-postcss-px2rem
v2.0.0
Published
According to one stylesheet, generate rem version and @1x, @2x and @3x stylesheet
Downloads
2
Readme
hoo-postcss-px2rem
说明
基于postcss-px2rem 修改, 新增excludeMinValue(<=不编译),excludeFile(忽略文件)
安装
git clone https://gitlab.com/hoosai/hoo-inject-html-webpack-plugin.git
npm install hoo-postcss-px2rem --save-dev
yarn add hoo-postcss-px2rem --dev
2.0.0
const defaultConfig = {
baseDpr: 2, // base device pixel ratio (default: 2)
remUnit: 100, // rem unit value (default: 100)
remPrecision: 5, // rem value precision (default: 5)
excludeMinValue: 1, // ignore min value (default: 1)
forcePxComment: 'px', // force px comment (default: `px`)
keepComment: 'no', // no transform value comment (default: `no`)
excludeFile: /[\\\/]node_modules[\\\/]/ // ignore /node_modules/ [function|string|regExp]
};