Declaring Inferred Type Parameters (Not Generic)
This declares a new type
The role of the infer keyword in conditional types is to check whether the type following infer actually exists, enabling accurate type inference
Too deep
type TrimLeft<T extends string> = T extends ` ${infer Rest}` ? TrimLeft<Rest> : T; // type Test = "hello" | "world" type Test = TrimLeft<" hello" | " world">;

Seonglae Cho