In Typescript is it possible to convert the union of keys from a mapped type to a tuple?
For example, using the following type as the input:
{
a: string;
b: number;
};
Can I output the type:
['a', 'b'];
In Typescript is it possible to convert the union of keys from a mapped type to a tuple?
For example, using the following type as the input:
{
a: string;
b: number;
};
Can I output the type:
['a', 'b'];