BerkinAKKAYA / svelte-image-gallery

A Masonry-Like Image Container for Svelte
https://madewithsvelte.com/svelte-image-gallery
52 stars 13 forks source link

No valid ES module #10

Closed GeneralMine closed 11 months ago

GeneralMine commented 2 years ago

When I'm using this npm module with sveltekit I will get these messages while compiling: svelte-image-gallery doesn't appear to be written in CJS, but also doesn't appear to be a valid ES module (i.e. it doesn't have "type": "module" or an .mjs extension for the entry point). Please contact the package author to fix.

It still works, so nothing has to be done urgently, but it remains to be necessary in the future

BerkinAKKAYA commented 2 years ago

Hi @GeneralMine. I converted the entry point to an mjs file and it seems to have solved it. Let me know if you are still getting the same warning please. Thanks a lot for the feedback!

ezfe commented 2 years ago

@BerkinAKKAYA When you did this, you forgot to update the main field in package.json

BerkinAKKAYA commented 2 years ago

Thanks @ezfe, fixed it ✅