mirror of
https://github.com/microsoft/TypeScript-Node-Starter.git
synced 2025-11-10 00:37:34 +00:00
Simplify augmented module for express-flash
There is existing @types definition for express-flash. Let's use it and just augment a method required by the existing code to please compiler. Thanks!
This commit is contained in:
10
src/types/express-flash.d.ts
vendored
10
src/types/express-flash.d.ts
vendored
@@ -1,9 +1,13 @@
|
||||
|
||||
/// <reference types="express" />
|
||||
|
||||
// Add RequestValidation Interface on to Express's Request Interface.
|
||||
/**
|
||||
* This type definition augments existing definition
|
||||
* from @types/express-flash
|
||||
*/
|
||||
declare namespace Express {
|
||||
interface Request extends Flash {}
|
||||
export interface Request {
|
||||
flash(event: string, message: any): any;
|
||||
}
|
||||
}
|
||||
|
||||
interface Flash {
|
||||
|
||||
Reference in New Issue
Block a user