rem的在vue项目中使用配置,,浏览器的兼容性之Mate标签

在vue中配置rem

位置:在APP.vue的script中,在export default之外

(()=>{

  let winW = document.documentElement.clientWidth,

  desW = 1440,

  htmlFont = winW / desW * 100;

  window.htmlFont = htmlFont;

  document.documentElement.style.fontSize = htmlFont + 'px';

})()

 

浏览器的兼容性之Mate标签

在vue项目index.html中

是否启用WebApp全屏模式,删除苹果默认的工具栏

<mate name="apple-touch-fullscreen" content="yes" />

启用360极速模式

<mate name="renderer" content="webkit" />

针对老的手持设备优化,不识别viewport

<mate name="HandheldFriendly" content="true" />

uc强制竖屏

<mate name="screen-orientation" content="portrait" />

QQ强制竖屏

<mate name="x5-orientation" content="portrait" />

UC强制全屏

<mate name="full-screen" content="yes" />

qq强制全屏

<mate name="x5-fullscreen" content="true" />

UC应用模式

<mate name="browsermode" content="application" />

QQ应用模式

<mate name="x5-page-mode" content="app" />

windows phone 点击无高光

<mate name="msapplication-tap-highlight" content="no" />

不被显示为拨号连接

<mate name="format-detection" content="telephone=no" />

优先使用IE最新版本和chrome

<mate http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" >

浏览器页面头像

<link rel="shortcut icon" href="图片路径" type="image/x-icon"/>

 

转载于:https://www.cnblogs.com/MisterHe/p/10232310.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值