vue移动端vant+postcss适配

2022-03-07  本文已影响0人  萤火kin
// 在.babelrc 或babel.config中添加配置
{
  "plugins": [
    ["import", {
      "libraryName": "vant",
      "libraryDirectory": "es",
      "style": true
    }]
  ]
}
// postcss.config.js
module.exports = {
  plugins: {
    'postcss-pxtorem': {
      rootValue: 37.5,
      propList: ['*'],
    },
  },
};
上一篇 下一篇

猜你喜欢

热点阅读