UNPKG

vhost-ts

Version:

vhost fork made with typescript

25 lines (24 loc) 579 B
declare type vhostPopulation = { host: string; hostname: string; length: number; [n: number]: string | undefined; }; declare global { namespace Express { interface Request { vhost: vhostPopulation; } } } import { RequestHandler } from "express"; declare const _default: (hostname: string | RegExp, handle: RequestHandler) => RequestHandler; /** * Create a vhost middleware. * * @param {string|RegExp} hostname * @param {function} handle * @return {Function} * @public */ export default _default;