在使用了amfe-flexible自动px转rem的插件后。

遇到过这个问题,发现无解啊,只要在组件的style里面书写大写的Px单位,vetur都会给你自动转成小写,很尴尬,特别是在用scss的情况下,组件内通过大小单位来让元素大小不自动转rem,无法完成,除非你关闭自动格式化,但是那是不可能的,太难了。

有种鱼和熊掌不可兼得的感觉。

但是作为一个成年人,怎么可能要做选择,我都要...

这个办法也是我灵光一现,突然有的,我说下我的思路。

此处内容已隐藏回复后方可阅读。

分类: vue 项目实战 标签: vetur自动格式化rem大写Px

评论

全部评论 22

  1. LLL
    LLL
    Google Chrome Windows 10
    说说
  2. 111
    111
    Google Chrome Windows 10
    按说
  3. 大白
    大白
    Google Chrome MacOS
    愿闻其详
  4. m12
    m12
    Google Chrome Windows 10
    字数补丁
  5. nn
    nn
    Google Chrome Windows 10
    萨达
  6. 123123
    123123
    Google Chrome MacOS
    康康
  7. 贾贾
    贾贾
    Google Chrome Windows 10
    愿闻其详
  8. 啥?
    啥?
    Google Chrome Windows 10
    抖抖抖
  9. 1
    1
    Google Chrome Windows 10
    积分加三告辞
  10. c
    c
    Google Chrome Windows 10
    天ttttt

目录