if (!isIE9) {
import 'swiper/dist/css/swiper.min.css'
} else {
import 'swiper2/dist/idangerous.swiper.css'
}
如上会报错'import' and 'export' may only appear at the top level
由于项目需要支持ie9,有部分组件使用了swiper,想要在较新的浏览器中用较新的样式,ie9用较老的版本,有什么办法实现呢?技术栈为vue.js
<!--[if lt IE 9]> <link rel="stylesheet" type="text/css" href="ie8-and-down.css"/> <![endif]-->