Assume I have a function type, e.g.
type somefntype = (a: number, b: string, c: boolean) => void
I need the type of that function types
As of TypeScript 4.0 with variadic tuple support, it's also possible to use the following to get the last type in a tuple type:
type LastType]> = T extends [...infer A, infer L] ? L : never;