Skip to content

Commit

Permalink
docs: mention default port change from vitejs#8148
Browse files Browse the repository at this point in the history
  • Loading branch information
sapphi-red committed May 31, 2022
1 parent 75a1c2a commit f1d8063
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/guide/migration.md
Expand Up @@ -27,6 +27,8 @@ A small fraction of users will now require using [@vitejs/plugin-legacy](https:/

## Dev Server Changes

Vite's default dev server port is now 5173. You can use [`server.port`](../config/server-options.md#server-port) to set it to 3000.

Vite optimizes dependencies with esbuild to both convert CJS-only deps to ESM and to reduce the number of modules the browser needs to request. In v3, the default strategy to discover and batch dependencies has changed. Vite no longer pre-scans user code with esbuild to get an initial list of dependencies on cold start. Instead, it delays the first dependency optimization run until every imported user module on load is processed.

To get back the v2 strategy, you can use [`optimizeDeps.devScan`](../config/dep-optimization-options.md#optimizedepsdevscan).
Expand Down

0 comments on commit f1d8063

Please sign in to comment.