diff --git a/types.d.ts b/types.d.ts index 9e56502..2ab9a02 100644 --- a/types.d.ts +++ b/types.d.ts @@ -4,9 +4,11 @@ import type {Request, RequestHandler} from 'express-serve-static-core'; declare global { namespace Express { // Inject additional properties on express.Request - type Request = { + // Should be interface to support declaration merging. + // eslint-disable-next-line @typescript-eslint/consistent-type-definitions + interface Request { id: string; - }; + } } }