question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Code organization

See original GitHub issue

How I should organize my code with this library? If my project have many queries and mutations, how to correctly split it? For example, ASP.NET uses MVC architecture and we can put code in different controllers and areas. I tried to create multiple QueryType, but seems this is not working. Only the last QueryType was created, and others were just skipped.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:24 (19 by maintainers)

github_iconTop GitHub Comments

1reaction
michaelstaibcommented, Jul 29, 2018

Yes, I think this is a really good idea. We, will first focus on closing the last spec gaps with Version 0.4.0 and 0.5.0. After that we will focus on the configuration API.

I originally had three workflows in mind:

  1. Schema-First

    Create your schema with the GraphQL syntax and than bind .net types to it.

  2. Code-First

    Define your schema with csharp.

  3. Mixed-Mode

    Merge schema-first and code-first with parts defined in the graphql syntax and other parts defined in csharp

But know I think we will allow for a 4th workflow where we flavour it like ASP.net. In this workflow you do not have to bother about the schema. You just create your controller like types and we will create from those a schema.

I will talk this through with my colleagues

0reactions
michaelstaibcommented, Nov 20, 2018

Also everything that you can do with the attributes now is available through the type api. you can also mix and match with these.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Four Strategies for Organizing Code | by Martin Sandin
Code organization is not about communicating with the computer but rather all about trying to make sure that people can understand the code...
Read more >
Code.org: Learn today, build a brighter tomorrow.
Discover the groundbreaking world of artificial intelligence (AI) and its transformative potential in education with our foundational online learning series for ...
Read more >
The Art of Code Organization
Avoid simply repeating your framework patterns. Start by organizing your code by affinity and keep rearranging the code with each iteration.
Read more >
Code Organization Concepts
In this chapter, we'll take a look at various code organization patterns you can use in your jQuery application and explore the RequireJS...
Read more >
CODE: Promoting Every Child's Right to Read
We have transformed the lives of over 10 million children through access to great books and great teachers. You can help us reach...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found