0
0
mirror of https://github.com/honojs/hono.git synced 2024-12-01 11:51:01 +01:00
hono/deno_dist/mod.ts
Jayden 760ae30251
Fix detecting node runtime (#696)
* Fix

* Denoify

* Avoid error in other runtime

* chore: remove unnecessary config testPathIgnorePatterns (#697)

* Fix vercel

Co-authored-by: Horie Issei <issei.horie@is2ei.com>
2022-12-02 11:28:49 +09:00

39 lines
1.1 KiB
TypeScript

import { Hono } from './hono.ts'
declare global {
class ExtendableEvent extends Event {
constructor(type: string, init?: EventInit)
waitUntil(promise: Promise<void>): void
}
abstract class FetchEvent extends ExtendableEvent {
readonly request: Request
respondWith(promise: Response | Promise<Response>): void
passThroughOnException(): void
}
interface ExecutionContext {
waitUntil(promise: Promise<void>): void
passThroughOnException(): void
}
}
export type {
Next,
ContextVariableMap,
MiddlewareHandler,
ErrorHandler,
NotFoundHandler,
} from './types.ts'
import type { CustomHandler } from './types.ts'
export type { CustomHandler as Handler }
export type { Context } from './context.ts'
export { Hono }
// Router
export { RegExpRouter } from './router/reg-exp-router/index.ts'
export { TrieRouter } from './router/trie-router/index.ts'
export { StaticRouter } from './router/static-router/index.ts'
export { SmartRouter } from './router/smart-router/index.ts'
// Validator
export type { Validator } from './validator/validator.ts'