Skip to content
This repository has been archived by the owner on Dec 7, 2021. It is now read-only.

thomasstep/nestedResolvers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

nestedResolvers

Run npm install then node app.js.

Sample query:

query {
  university(name: "something") {
    colleges {
      dean {
        awards
        name
      }
      notableGraduates
      numberOfStudents
    }
    cost {
      tuition
      averageBooks
      averageFinancialAid
      costOfLiving
    }
  }
}

This is meant to accompany a blog post I wrote about writing GraphQL resolvers. To keep everything simple, the "data sources" are just hardcoded values and the university's name input does not matter. This is more to show how to write functions that will correctly resolve the given schema.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published