Closed as not planned
Description
Documentation is
- Missing
- Outdated
- Confusing
- Not sure?
Explain in Detail
After upgrading from the latest v6 to Vite 7, our build started failing with the following message (path names are redacted with XXX):
failed to load config from /Users/XXX/packages/icons-web/build/external/vite.config.ts
error during build:
Error [ERR_REQUIRE_ESM]: require() of ES Module /Users/XXX/node_modules/vite/dist/node/index.js from /Users/XXX/packages/icons-web/build/external/vite.config.ts not supported.
Instead change the require of index.js in /Users/XXX/packages/icons-web/build/external/vite.config.ts to a dynamic import() which is available in all CommonJS modules.
at _require.extensions.<computed> [as .js] (file:///Users/XXX/node_modules/vite/dist/node/chunks/dep-Bsx9IwL8.js:36481:9)
at TracingChannel.traceSync (node:diagnostics_channel:315:14)
at Object.<anonymous> (/Users/XXX/packages/icons-web/build/external/vite.config.ts:36:19)
The migration guide states that v22.12+ is required, but this is broken for us on v22.12. https://vite.dev/guide/migration.html
Updating to v22.13.0+ resolves the issue, so the documentation may just need updated to state that v22.13.0+ is the required version.
Your Suggestion for Changes
Please update the migration guide for Vite 7 to state that Node v22.13.0+ is required
Reproduction
No response
Steps to reproduce
No response