Is it possible to convert union type in Typescript to array type which requires to have all of the values defined in union type?
type Colors = "primary" | "secondary" | "error";
I would like it to convert to:
type ColorsArray = ["primary", "secondary", "error"];