vue-upload-multiple-image icon indicating copy to clipboard operation
vue-upload-multiple-image copied to clipboard

passenger error: Unexpected token import

Open dwfee opened this issue 5 years ago • 1 comments

I want to use your component within a nuxt project. Everything work fine, exept when I reload a link to a page where the component is used. Then I get passenger error: Unexpected token import. I importet the component directly on this page. All my trials to register the component befor as a plugin, did not work. I guess there must be some import statements at the beginning of vue-upload-multiple-image passenger does not like. Passenger accepts only require. Any idea to fix this? How to make it work with nuxt using express server over passenger? When transpiling 'vue-upload-multiple-image','vue-image-lightbox-carousel','vue-awesome-swiper', I end up getting window is not defined from vue-awesome-swiper.js

dwfee avatar May 28 '20 11:05 dwfee

Fixed it myself. Using an async Component: const VueUploadMultipleImage = () => ({ component: import('vue-upload-multiple-image'), loading: Loading, // not work error: Error, // good delay: 10, // not work timeout: 3000 // good });

dwfee avatar May 29 '20 04:05 dwfee