Skip to content

Instantly share code, notes, and snippets.

@przemyslawjanpietrzak
Created October 10, 2018 12:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save przemyslawjanpietrzak/dbb99e875e85e2b7c95796c664e833c8 to your computer and use it in GitHub Desktop.
Save przemyslawjanpietrzak/dbb99e875e85e2b7c95796c664e833c8 to your computer and use it in GitHub Desktop.
interface X {
key1: string;
key2: { id: number, name: string },
key3: number;
}
const fn = (arg: X['key2']) => {
arg.id // number
arg.name // string
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment