murongg / vue3-lazyload

A Vue3.x image lazyload plugin
https://murongg.github.io/vue3-lazyload/
172 stars 20 forks source link

[error] may need an appropriate loader to handle this file type #31

Open KBKUN024 opened 2 years ago

KBKUN024 commented 2 years ago

The error in command is below:

image

Actually,I use it follow documentation,is the image below: image But command notice me that I need a appropriate loader to handle this file,how can I fix it?

KBKUN024 commented 2 years ago

which loader should I use?

KBKUN024 commented 2 years ago

In my code,main.js:

image
murongg commented 2 years ago

Are you use vue-cli default config?

murongg commented 2 years ago

You need find a webpack loader load .mjs file.

KBKUN024 commented 2 years ago

yes,I'm sure

发自我的iPhone

------------------ Original ------------------ From: 木荣 @.> Date: Wed,Jul 20,2022 9:23 PM To: murongg/vue3-lazyload @.> Cc: KBKUN024 @.>, Author @.> Subject: Re: [murongg/vue3-lazyload] [error] may need an appropriate loader tohandle this file type (Issue #31)

Are you use vue-cli default config?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

murongg commented 2 years ago

I tried use vue-cli create default config project. This error did not occur.

murongg commented 2 years ago

What version are you using?

Bataino commented 2 years ago

I am also facing the error

Andrii-Khoptii commented 2 years ago

What version are you using?

Vue 3.2.22 ts

Aseisman commented 2 years ago

the same to me .waiting for the solution ~

murongg commented 2 years ago

@Xudadaaa Try to check the dependent version related to vue or vite.

tsoil commented 2 years ago

原因应该是不支持?的语法,需要load加载,具体要用那个load?

murongg commented 2 years ago

@tsoil 我使用了 vite 与 vue-cli 的默认模板,没有发现什么问题,所以我也很困惑。

Aseisman commented 2 years ago

@Xudadaaa Try to check the dependent version related to vue or vite.

升级版本就可以啦 thanks