A minimal Cloudflare Workers project with bknd integration.
This project uses:
- Bknd.io - bknd is a lightweight, infrastructure agnostic and feature-rich backend that runs in any JavaScript environment.
- Hono - Hono web server and Hono JSX components for server-side rendering
- DataStar - Progressive enhancement with HTML attributes for interactivity
- Tailwind CSS - Utility-first CSS framework
- DaisyUI - Tailwind component library
/
├── src/
│ ├── index.tsx # Main entry point with Cloudflare Workers adapter
│ ├── components/ # Hono.jsx components
│ ├── layouts/ # Layout components
│ ├── pages/ # Page components
│ └── styles/ # Global CSS (Tailwind + DaisyUI)
├── config.ts # Main bknd configuration
├── bknd.config.ts # Wrapped config for type generation
├── package.json
└── wrangler.json
To update bknd config, check config.ts.
All commands are run from the root of the project:
| Command | Action |
|---|---|
bun install |
Installs dependencies |
bun run dev |
Starts local dev server with CSS watch at localhost:8787 |
bun run typegen |
Generates wrangler and bknd types |
If you're using a D1 database, make sure to create a database in your cloudflare account and replace the database_id accordingly in wrangler.json.
npx wrangler d1 create my-databaseFeel free to check our documentation or jump into our Discord server.