2022-07-02 06:09:45 +00:00
|
|
|
import { Hono } from './hono.ts'
|
|
|
|
|
|
|
|
declare global {
|
2022-07-17 09:36:42 +00:00
|
|
|
class ExtendableEvent extends Event {
|
|
|
|
constructor(type: string, init?: EventInit)
|
|
|
|
waitUntil(promise: Promise<any>): void
|
|
|
|
}
|
|
|
|
abstract class FetchEvent extends ExtendableEvent {
|
2022-07-02 06:09:45 +00:00
|
|
|
readonly request: Request
|
2022-07-17 09:36:42 +00:00
|
|
|
respondWith(promise: Response | Promise<Response>): void
|
|
|
|
passThroughOnException(): void
|
2022-07-02 06:09:45 +00:00
|
|
|
}
|
|
|
|
interface ExecutionContext {
|
|
|
|
waitUntil(promise: Promise<any>): void
|
|
|
|
passThroughOnException(): void
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export type { Handler, Next } from './hono.ts'
|
2022-07-10 14:44:23 +00:00
|
|
|
export type { Context } from './context.ts'
|
2022-07-02 06:09:45 +00:00
|
|
|
export { Hono }
|
|
|
|
|
|
|
|
// Router
|
|
|
|
export { RegExpRouter } from './router/reg-exp-router/index.ts'
|
|
|
|
export { TrieRouter } from './router/trie-router/index.ts'
|