djbalinD
Convex Community11mo ago
3 replies
djbalin

How to print tablename from generic type?

I'm trying to write a getDocOrThrow helper along the lines of whats shown in the screenshot. I would like to also be able to pass an _id for data correction purposes. I would also need to print the table of the referencing document, otehrwise it's too hard to track down from _id on its own . Can this be done?

.__tableName doesn't work, it just resolves to
undefined
. Can't I somehow print the tablename from my generic type R?
08d614c0-68f3-4cf7-8436-eaf827ca74f9.png
Was this page helpful?