-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Add svelte exports field to package json when running package command #1959
Copy link
Copy link
Closed
Labels
p1-importantSvelteKit cannot be used by a large number of people, basic functionality is missing, etc.SvelteKit cannot be used by a large number of people, basic functionality is missing, etc.pkg:svelte-packageIssues related to svelte-packageIssues related to svelte-package
Description
Describe the problem
SvelteKit currently has a heuristic in place which tells Vite which packages are Svelte packages (for noExternal stuff) by looking up the package.json content and seeing if there's a svelte property.
The svelte-kit package command does not currently set this field.
Describe the proposed solution
Use the same logic that is used for the main entry to produce a svelte entry.
Alternatives considered
A workaround for now is for users to specify this field in their package.json themselves as it's copied over as of lately.
Importance
would make my life easier
Additional Information
The svelte key is likely more of a historical thing at this point, and deserves some more thought regarding the new developments, but for now the quick fix is to just add this field
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
p1-importantSvelteKit cannot be used by a large number of people, basic functionality is missing, etc.SvelteKit cannot be used by a large number of people, basic functionality is missing, etc.pkg:svelte-packageIssues related to svelte-packageIssues related to svelte-package