# Install dependencies
$ yarn
# Start local dev
$ yarn start
- create dev server to serve code file and deps
- mount http middleware for route registration
- module graph initialization
- initialize Plugin container (for different assets support)
- perform deps optimizer (this is to pre bundle the 3rd party deps so you have a fast dev experiences)
- wait for browser
import
requests.
Step 5 is the secret weapon why Vite is fast. Optimizer
will found the code entry point and perform importing
scan. Then esbuild
and esbuldScanPlugin
will perform pre-compiling for 3rd party deps.
- pnpm as the package manager
- tsx for the running of ts code.
- Compilation:
rollup
for Vite main business code.unbuild
for Vite plugin code. - api-extractor for Typescript declaration file bundling.
- bundled code is
ESM
, but CJS-proxy is provided for commonjs scenario.