22 lines
393 B
Markdown
22 lines
393 B
Markdown
|
|
```txt
|
||
|
|
npm install
|
||
|
|
npm run dev
|
||
|
|
```
|
||
|
|
|
||
|
|
```txt
|
||
|
|
npm run deploy
|
||
|
|
```
|
||
|
|
|
||
|
|
[For generating/synchronizing types based on your Worker configuration run](https://developers.cloudflare.com/workers/wrangler/commands/#types):
|
||
|
|
|
||
|
|
```txt
|
||
|
|
npm run cf-typegen
|
||
|
|
```
|
||
|
|
|
||
|
|
Pass the `CloudflareBindings` as generics when instantiation `Hono`:
|
||
|
|
|
||
|
|
```ts
|
||
|
|
// src/index.ts
|
||
|
|
const app = new Hono<{ Bindings: CloudflareBindings }>()
|
||
|
|
```
|