What is the purpose of exporting relations

https://orm.drizzle.team/docs/rqb#declaring-relations What is the purpose of exporting declared relations? Also, I feel like it would make sense that relations would be an optional argument in pgTable, not a separately declared item
Drizzle ORM - next gen TypeScript ORM
Drizzle ORM is a lightweight and performant TypeScript ORM with developer experience in mind.
2 Replies
jakeleventhal
jakeleventhalOP13mo ago
I suppose its needed to be included in the constructor of the db client, but still, why not just include as part of the pgTable definition
Angelelz
Angelelz13mo ago
It's the design of the API
Want results from more Discord servers?
Add your server