lekhang2512 / vue-upload-multiple-image

A simple upload multiple image component for Vuejs
132 stars 50 forks source link

Couldn't import in nuxt #44

Open BEEugene opened 3 years ago

BEEugene commented 3 years ago

Hi!

I've tried to use the package in Nuxt.js. It worked almost perfectly, when in a dev mode. Unfortunately, I receive this error "Cannot use import statement outside a module"

I've tried to fix it with this https://github.com/WouterFlorijn/vue-stack-grid/issues/11#issuecomment-663921874

image

Any ideas what am I doing wrong?

BEEugene commented 3 years ago

That is an interesting problem. Here is a sample project If you run it in a dev mode and go to the test page via a button on the home page - you will not get any error. If you will try to go there - the aforementioned error will rise. You also will not able to build this project correctly.

BEEugene commented 3 years ago

A Github project example.

And my findings on this theme (still some support is needed).

BEEugene commented 3 years ago

I was able to import it. Here is the description. It will be nice if you add it to the documentation.