html5 - Why does post-css not automatically add the browser prefix to css3 attributes when using vue cli scaffolding?
过去多啦不再A梦2017-05-16 13:36:14
0
3
1178
1. Why is the browser prefix not automatically added to css3 attributes when using the scaffolding on the vuejs official website? For example: transform: tralaste(50%, 0); does not add -webkit, -moz and other browser prefixes
你说的是在dev阶段没有给你加前缀吧, dev阶段没有配置autoprefixer, build阶段有.
其实没必要在dev阶段开启autoprefixer, 这样编译不就慢了吗(虽然微小慢),开发时候针对当前浏览器开启前缀就够了
新建postcss.config.js
配置autoprefixer
解决了,在webpack.base.config.js中配置