参考bootstrap3的文档以及(https://github.com/scottjehl/Respond/),下载response.js 引入到html页面中

下面是关键代码

<link href="css/test.css" rel="stylesheet"/>
<link href="css/test2.css" media="screen and (max-width: 1366px)" rel="stylesheet"/> 
<script src="js/response.1.4.2.js"></script>

***************必须在服务器运行,例如本地服务器(http://localhost:3366/vue.html)本地文件不能访问,亲测本地访问的话,文件response在ie8中拒绝访问

ie8 如何支持@media screen and (max-width: 1366px)

test.css代码如下

body {
    background: red;
}

test2.css代码如下

@media screen and (max-width: 1366px){
    body {
        background: green;
    }
}

相关文章:

  • 2022-12-23
  • 2021-11-08
  • 2022-12-23
  • 2022-12-23
  • 2021-12-02
  • 2022-01-17
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-11-23
  • 2022-12-23
相关资源
相似解决方案