Tuplify the keys types

Viewed 19

Is there a way in typescript to do the following:

type Foo = {
  code?: string;
  name: string;
  bar: number;
}

let bar: Tuple<Foo>; // a: [string | undefined, string, number]
0 Answers
Related