Created
April 29, 2019 10:22
-
-
Save aal89/481993b7c56653b50792fc1d7f79a611 to your computer and use it in GitHub Desktop.
Declaration merging. Swift like extensions for TypeScript. Extending an Express Request object per example.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// tslint:disable | |
declare namespace Express { | |
export interface Request { | |
locals: { | |
data: unknown; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment