npm packages
Rough order of adoption:
| Package | Role |
|---|---|
| @viewfly/core | Core: components, reactivity, signal, JSX runtime, lifecycle, inject, etc. |
| @viewfly/platform-browser | Browser: createApp, mount, destroy. |
| @viewfly/router | Routing: RouterModule, Link, RouterOutlet, etc. |
| @viewfly/devtools | Build: *.scoped.* styles with Vite / Rollup / Webpack; includes component HMR for the Vite dev server (not loaded in production builds). |
| @viewfly/cli | CLI: Vite + TypeScript project templates. |
Router and scoped CSS are optional. Scoped CSS needs @viewfly/core (e.g. withMark) and @viewfly/devtools. The official Vite template from the CLI installs @viewfly/devtools and enables HMR by default; in your own setup, follow the @viewfly/devtools readme on npm to wire vite-viewfly-hmr-plugin.