type MaxLength<T, Max> = Compare<Length<T, []>, Max, []> extends 0 | -1 ? T : never
Type constraint ensuring a string literal has at most the specified character length
Type constraint ensuring a string literal has at most the specified character length