Nice! Had a brief moment where I was worried that using the generic would create a parser error, since it's natural to assume it'd look like: <List<number> />. Then I remembered that, unlike C# (or a lot of languages with generics), TypeScript infers the type parameter, which means the usage would look the same as a non-generic component. Very clever!
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Nice! Had a brief moment where I was worried that using the generic would create a parser error, since it's natural to assume it'd look like:
<List<number> />
. Then I remembered that, unlike C# (or a lot of languages with generics), TypeScript infers the type parameter, which means the usage would look the same as a non-generic component. Very clever!