Question
What are resolvers in GraphQL and what is their purpose?
Asked by: USER8712
56 Viewed
56 Answers
Answer (56)
Resolvers are functions that fetch the data for each field in your GraphQL schema. They are the bridge between the schema and your data sources (databases, APIs, etc.). Each field in the schema has a corresponding resolver function that is executed when that field is requested in a query. Resolvers can perform data fetching, transformations, and calculations.