Swiper CDN

如果你不想将Swiper文件放在你的项目中,你可以使用Swiper的CDN服务。
风险提示:CDN由于不稳定性,在生产环境中请谨慎使用。

swiper5
<link rel="stylesheet" href="https://unpkg.com/swiper/css/swiper.css">  
<link rel="stylesheet" href="https://unpkg.com/swiper/css/swiper.min.css">    
<script src="https://unpkg.com/swiper/js/swiper.js"> </script>  
<script src="https://unpkg.com/swiper/js/swiper.min.js"> </script>

swiper4/swiper3,要将4.x.x改成相应的版本,如4.0.2(或3.x.x版本)
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/Swiper/4.x.x/css/swiper.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/Swiper/4.x.x/css/swiper.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/Swiper/4.x.x/js/swiper.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Swiper/4.x.x/js/swiper.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Swiper/4.x.x/js/swiper.esm.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Swiper/4.x.x/js/swiper.esm.bundle.js"></script>


请勿直接引入Swiper中文网的文件

x <script src="http://www.swiper.com.cn/dist/js/swiper.min.js"></script>

x <link href="http://www.swiper.com.cn/dist/css/swiper.min.css" />