Skip to content

Instantly share code, notes, and snippets.

@JavadocMD
Created August 23, 2019 07:21
Show Gist options
  • Save JavadocMD/ef95084a058d6a89329425ee7a20d06e to your computer and use it in GitHub Desktop.
Save JavadocMD/ef95084a058d6a89329425ee7a20d06e to your computer and use it in GitHub Desktop.
Extending Window in Typescript.
// This file would go in your source path, e.g.: src/window.d.ts
declare interface Window {
foo: string
}
@JavadocMD
Copy link
Author

And this file needs to be included by your tsconfig

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment