update package.json for vite5 / svelte 3
Closed this issue · 4 comments
hello,
first, I'm happy to use this library.
But recently I faced an issue with vite-plugin-svelte
and vite5
When this library was made, these components were older :-)
Here is the issue:
sveltejs/vite-plugin-svelte#813
it seems svelte-fa is not following new recommended approach for svelte usage.
Running it now I can see
[vite-plugin-svelte] WARNING: The following packages have a svelte field in their package.json but no exports condition for svelte.
svelte-fa@3.0.4
Please see https://github.com/sveltejs/vite-plugin-svelte/blob/main/docs/faq.md#missing-exports-condition for details.
and here is the recommandation provided in the vite plugin svelte issue
My recommendation would be to switch to svelte-package , add "type": "module", add an "exports" map , add publint to verify their package.json is ok. And last but not least maybe don't do mixed exports (default and named) from the index file. Thats not great.
I don't know if you would accept such PR ?
hello, I forgot
I'm not working on it right now
@Cweili Example of another package that had to make similar changes: fedorovvvv/svelte-floating-ui@a1f7bee