How to define type of table with all relations included?
Say I have a a table users and a user has many posts, so I define a relationship as shown in the docs
If I want to define a type that is "user with posts" that would be the result of:
the type of this would be something like
Is there a cleaner way to define that where all the relations are just included and automatically inferred?
If I want to define a type that is "user with posts" that would be the result of:
the type of this would be something like
Is there a cleaner way to define that where all the relations are just included and automatically inferred?