import { Request as ExpressRequest } from 'express'; import { IdentityBill } from './types'; // tslint:disable-next-line: interface-over-type-literal export type StringTo = { [key: string]: T }; // tslint:disable-next-line: interface-over-type-literal export type IdentityTag = { identity: TIdentity; }; export type ExpressRequestWithLocals = ExpressRequest & { locals: StringTo; }; export type IdentifiedExpressRequest< TIdentity extends IdentityBill = IdentityBill > = ExpressRequestWithLocals & IdentityTag;