1%","last2versions","notie=8","and 白云城资源网更新日期:2024/5/17" />
网络编程 
首页 > 网络编程 > 浏览文章

vscode中使用Autoprefixer3.0无效的解决方法

(编辑:jimmy 日期: 2024/5/17 浏览:3 次 )

问题

一开始安装的Autoprefixer是最新版本的3.0.1,一波操作后发现无效
想是不是因为没设置browsers?那就设置一下吧

"autoprefixer.browsers": [
 "> 1%", 
 "last 2 versions",
 "not ie <= 8",
 "ios >= 8", 
 "android >= 4.0"
],

是在setting.json文件添加了这个设置后,一波操作后,css丝毫没有变化,无效啊!!!这时候就要找度娘问问了,
然而在网上冲浪,找啊找,都找不到对应的办法。网上都是说在那里配置autoprefixer.browsers,啥也不是。。
然后看到一个文章说3.0.0版本下设置autoprefixer.browsers无效的。。好吧,这算是知道原因了。
https://www.jb51.net/article/188292.htm

那高配不行,为降下来咯,然后我就把Autoprefixer版本减低到2.2.0

vscode中使用Autoprefixer3.0无效的解决方法

解决

然后就可以配置了,完美解决~~~~

vscode中使用Autoprefixer3.0无效的解决方法

测试一下

vscode中使用Autoprefixer3.0无效的解决方法

选中当前css文件,按ctrl+shift+p,然后选择autoprefixer,就可以自动补全了,哈哈

vscode中使用Autoprefixer3.0无效的解决方法

上一篇:详解VScode自动补全CSS3前缀插件以及配置无效的解决办法
下一篇:lambda 表达式导致 Arthas 无法 redefine 的问题