mirror of
https://github.com/honojs/hono.git
synced 2024-12-01 10:51:01 +00:00
9f5b7298ab
* fix(factory): fixed the comment * denoify
12 lines
396 B
TypeScript
12 lines
396 B
TypeScript
import type { Env, Input, MiddlewareHandler } from '../../types.ts'
|
|
|
|
/**
|
|
* @experimental
|
|
* `createMiddleware()` is an experimental feature.
|
|
* The API might be changed.
|
|
*/
|
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
export const createMiddleware = <E extends Env = any, P extends string = any, I extends Input = {}>(
|
|
middleware: MiddlewareHandler<E, P, I>
|
|
) => middleware
|