Static GitHub Issues

[1251] how to new a Obj from static js file not import

prev: syntax-optional-chaining isn't working
next: how to add a local minify js

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: image

why can't i use import the swiper file please check #1250
thank for some one to solve my problem :)

<!--cmty--><!--cmty_prevent_hook--><div align="right"><sub><em>This question is available on <a href="https://nuxtjs.cmty.io">Nuxt.js</a> community (<a href="https://nuxtjs.cmty.io/nuxt/nuxt.js/issues/c1108">#c1108</a>)</em></sub></div>