-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
More complex project examples #20
Comments
Yes. You can certainly have a single schema and query, and have as many operations based on that as needed. In our more complex projects, that's how it's setup.
This sounds correct.
As this is such a new library, best practices are evolving. But, as it stands, that's the best way to do it.
This could be a good idea for a new feature. It would certainly make managing the DI environment easier (e.g. no more "ah heck, I forgot to add it to DI") |
Thank you @dougrday, your input was exactly what I was looking for. |
I'll be adding more complex examples to the project as part of this issue. Stay tuned... |
Great! Looking forward to it. |
@nunogois OK, I've implemented some more complex examples. It includes:
|
Hi, I'm trying to implement Dapper.GraphQL and streamline the process of adding our several models.
The existing examples are great but I'm having a bit of difficulty on understanding how to put the pieces together when considering several models in a big project. Based on the existing examples, is it possible to have a single Schema for all of our queries, for example? If not, how should I properly DI them into my single GraphQL controller? The example seems a bit locked on PersonSchema.
Also, should I just assume we'll need an EntityMapper, Query, QueryBuilder, Schema, Type and Model for each Model in our business logic, from which we manually add each Type, Query, Schema and QueryBuilder to DapperGraphQL options on services configuration @ Startup.cs? Would that be best practice? Is there any way to do so dynamically?
Some hints would be greatly appreciated!
The text was updated successfully, but these errors were encountered: