Courses / Node.js
29. GraphQL resolvers
Implement resolver functions that fetch or modify data for GraphQL fields.
JavaScript
GraphQL resolvers
Functions that fetch or modify the data returned for GraphQL fields.
"I want each GraphQL field to run code that gets the right data, like calling a DB or composing values."
Resolvers are the functions you attach to GraphQL fields; when a query asks for a field, its resolver runs and returns the value (possibly async). They connect schema to real data sources and business logic.
"I want each GraphQL field to run code that gets the right data, like calling a DB or composing values."
Resolvers are the functions you attach to GraphQL fields; when a query asks for a field, its resolver runs and returns the value (possibly async). They connect schema to real data sources and business logic.