Example Vite + React + TypeScript app with a Hono worker on Cloudflare, configured for Webflow Cloud.
.
├── index.html
├── LICENSE
├── package.json
├── package-lock.json
├── public
│ ├── hono.svg
│ ├── vite.svg
│ └── webflow.svg
├── src
│ ├── App.tsx
│ ├── globals.d.ts
│ ├── main.tsx
│ ├── style.css
│ └── worker.ts
├── tsconfig.json
├── vite.config.ts
├── webflow.json
├── worker-configuration.d.ts
└── wrangler.json
src/main.tsx mounts the React app in src/App.tsx. src/worker.ts is the Hono
worker that serves the /api/hello endpoint and the built static assets.
| Command | Action |
|---|---|
npm install |
Install dependencies. |
npm run dev |
Start the Vite dev server (default http://localhost:5173). |
npm run build |
Production-build the app to dist/. |
npm run preview |
Serve the production build locally (default http://localhost:4173). |
npm run deploy |
Deploy to Webflow Cloud with the Webflow CLI. |
npm run cf-typegen |
Regenerate worker-configuration.d.ts from wrangler.json. |