https://github.com/o-az/h0n0
My base Hono template
https://github.com/o-az/h0n0
bun cloudflare-workers hono workers
Last synced: about 2 months ago
JSON representation
My base Hono template
- Host: GitHub
- URL: https://github.com/o-az/h0n0
- Owner: o-az
- Created: 2025-02-27T00:20:26.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2026-04-15T00:47:09.000Z (2 months ago)
- Last Synced: 2026-04-15T02:33:40.972Z (2 months ago)
- Topics: bun, cloudflare-workers, hono, workers
- Language: TypeScript
- Homepage: https://h0n0.evm.workers.dev
- Size: 451 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: .github/README.md
Awesome Lists containing this project
README
> [!NOTE] Personal [Hono](https://hono.dev) template. Feel free to use.
## Structure
- In [src/setup.ts](/src/setup.ts) we setup helpers, middlewares, and Hono plugins.
- In [src/index.ts](/src/index.ts) we setup routes.
## Get started
Install dependencies
```shell
# install / update bun to latest
npm install --global bun@latest
# install dependencies
bun install
# run dev
bun dev
```
## Deploy
If you're deploying to Cloudflare Workers:
```shell
# Authenticate with wrangler
bun x wrangler@latest login
# Deploy
bun x wrangler@latest deploy --config='wrangler.json' --keep-vars
```
---
If you're deploying somewhere else check the following:
1. Remove Cloudflare Workers specific files:
```shell
rm .dev.vars .dev.vars.example wrangler.json
```
2. Uninstall `@cloudflare/workers-types`:
```shell
bun remove @cloudflare/workers-types
```
3. Replace `hono/cloudflare-workers` in [src/setup.ts](./src/setup.ts) with the [appropriate adapter](https://hono.dev/docs/helpers/conninfo#conninfo-helper) for your deployment target
4. Remove `@cloudflare/workers-types` from `"types"` array in [tsconfig.json](./tsconfig.json)
5. Check [hono.dev](https://hono.dev/docs/getting-started/basic) for deployment instructions