I add a swiper.min.js as the doc How to use external resources? and i need new a swiper obj (simply the code ) like below :
export default {
head: {
script: [
{ src: '/swiper/swiper.min.js' }
],
link: [
{ rel: 'stylesheet', href: '/swiper/swiper.min.css' }
]
},
mounted () {
// simply the code
new Swiper('.swiper-container', {
pagination: '.swiper-pagination',
loop: true
})
},
}
then the console show error like this:
why can't i use import the swiper file please check #1250
thank for some one to solve my problem :)