Closed lifeiscontent closed 6 months ago
I am sorry but this is probably a perspective of preference here as I don't see this simplifying the types. 😅
Personally I prefer Array<T>
over T[]
especially with complex type, e.g. (A | B | C)[]
is much harder to read then Array<A | B | C>
. Similarly, Record<keyof any, unknown>
requires an additional thought of what keyof any
is.
@edmundhung hey no worries, I've closed the branch :)
simplifying types to resolved types.
Array<T>
->T[]
Record<string | number | symbol, unknown>
->Record<keyof any, unknown>
as it resolves to the same thing