1import express from 'express';
2import http from 'http';
3
4/** Headers */
5export type ServerHeaders = Map<string, number | string | readonly string[]>;
6/** Request */
7export type ServerRequest = express.Request | http.IncomingMessage;
8/** Response */
9export type ServerResponse = express.Response | http.ServerResponse;
10/** Next function */
11export type ServerNext = (err?: Error | null) => void;
12
13/** The `connect()` app that is a http.RequestListener and having the `use()` function for middlewares. */
14export interface ConnectAppType extends http.RequestListener {
15  use: Function;
16}
17