Skip to content

typescript-- How do you type generics? #382

Answered by Minigugus
RyanDurk asked this question in Q&A
Discussion options

You must be logged in to vote

Short answer: indeed, it's a bug... 😞

Long answer: historically, if was possible to pass types like number as row type, and these would be become { '?column?': T }, as postgresql does with unamed columns (like in SELECT 42;). But it was too painful and not really used so contraints on T where added, to enforce objects only (see types), then transforming to '?column?' isn't even possible anymore, so that part should have been removed, to avoid bugs like in your case 😅

A fix is on the way: #383

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by RyanDurk
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants