Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
mrkeen
· 2y ago · 0 comments
OK so what would you call them? TypeParam1, TypeParam2, ... ?
Comments
[–]
code_biologist
2y ago
A common convention I've seen is using T at the start of a type parameter, [1] for example. TKey, TData, TError, TSuccessCallback, etc. I always liked T at the end, but I've not seen that as often.
[1]
https://github.com/TanStack/query/blob/59a6d3df3035d6effeaed...
[–]
toastedwedge
2y ago
Seems apt that the error for a generic type would (and should) be spelled "terror."