You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
813 B

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

export default {
plugins: {
// 兼容浏览器,添加前缀
autoprefixer: {},
'postcss-pxtorem': {
rootValue: 37.5, //结果为:设计稿元素尺寸/16比如元素宽320px,最终页面会换算成 20rem
propList: ['*'], //是一个存储哪些将被转换的属性列表,这里设置为['*']全部,假设需要仅对边框进行设置,可以写['*', '!border*']
unitPrecision: 5, //保留rem小数点多少位
selectorBlackList: ['.radius'], //则是一个对css选择器进行过滤的数组比如你设置为['fs']那例如fs-xl类名里面有关px的样式将不被转换这里也支持正则写法。
mediaQuery: true, //媒体查询( @media screen 之类的)中不生效
minPixelValue: 12 //px小于12的不会被转换
}
}
}