You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Which would be solved by making Vite a peer and requiring all projects list a version of it in their package.json.
Is your feature request related to a bug?
N/A
What are the alternatives?
Keep it a subdependency. Only benefit here is WXT has control over the version of vite it uses, and can prevent people from trying a newer version, like v7, before it's ready.
It's easy to ignore peer dependency version warnings, while those should tell the user t hey have an invalid version installed.
Reacted by Eli, Yunsup Sim(심윤섭), Marius Bosler, Abdul Basit Rana, Thomas Barbier and Patt O'Brien
One idea that might help, Yarn & pnpm support "peer dependencies with defaults". If you include a package in both peerDependencies and dependencies, it'll act like a peer, but it'll be auto-installed npm-style unless you install your own version of Vite, in which case it'll inherit your version. In npm, it'll fall back to a normal dependency (status quo).
Gonna close this so it shows as complete on the v1.0 milestone. The PR has been merged and this change will be released in the next major version - no estimate on this right now.
Activity
lishaduck commentedon Oct 22, 2025
One idea that might help, Yarn & pnpm support "peer dependencies with defaults". If you include a package in both
peerDependenciesanddependencies, it'll act like a peer, but it'll be auto-installed npm-style unless you install your own version of Vite, in which case it'll inherit your version. In npm, it'll fall back to a normal dependency (status quo).References
Docs:
P.S. I'm back for at least a bit! 😛
aklinker1 commentedon Dec 18, 2025
Gonna close this so it shows as complete on the v1.0 milestone. The PR has been merged and this change will be released in the next major version - no estimate on this right now.