svelte-geolocation icon indicating copy to clipboard operation
svelte-geolocation copied to clipboard

"Missing exports condition" warning with vite-plugin-svelte

Open ornato-t opened this issue 1 year ago • 1 comments

When bundling with [email protected] and @sveltejs/[email protected] (after having updated to SvelteKit 2), I've been getting the following Vite warning:

[vite-plugin-svelte] WARNING: The following packages have a svelte field in their package.json but no exports condition for svelte.

[email protected]

Please see https://github.com/sveltejs/vite-plugin-svelte/blob/main/docs/faq.md#missing-exports-condition for details.

Reading from that link, it looks like a small change to the package.json file should fix this. My app runs just fine even with the warning, but according to the link this current structure is deprecated and support for it might be removed in the future.

Note: I have been getting this same warning with your svelte-search library, but opening two separate issues for the same problem sounds a bit overkill. I'd appreciate it if you could update both.

ornato-t avatar Dec 15 '23 10:12 ornato-t

Thanks for reporting, will take a pass at resolving these warnings.

metonym avatar Dec 15 '23 15:12 metonym

Also just ran into this issue. Looks like it hasn't been resolved yet.

DavyK17 avatar Jul 12 '24 16:07 DavyK17

The package is updated with an exports map in v1.0.0

metonym avatar Jul 13 '24 19:07 metonym