You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The growing number of findDmBy... and findGroupBy... findConversation... methods can become confusing and bloating the API.
It's also easier (IMO) for DX if I see just one method like findConversation and then I can pass args to build that query depending on what I need.
Describe the solution to the problem
Introduce a single method, like Prisma did with findUnique. This would consolidate queries and leverage TypeScript to enforce required arguments based on the criteria.
Describe the uses cases for the feature
No response
Additional details
Don't think it's worth changing anything now. Just a suggestion in case you planned to add more and more unique methods like that.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem?
No, only a suggestion.
The growing number of
findDmBy
... andfindGroupBy
...findConversation
... methods can become confusing and bloating the API.It's also easier (IMO) for DX if I see just one method like
findConversation
and then I can pass args to build that query depending on what I need.Describe the solution to the problem
Introduce a single method, like Prisma did with
findUnique
. This would consolidate queries and leverage TypeScript to enforce required arguments based on the criteria.Describe the uses cases for the feature
No response
Additional details
Don't think it's worth changing anything now. Just a suggestion in case you planned to add more and more unique methods like that.
The text was updated successfully, but these errors were encountered: