Core concepts

What is it

You can essentially do two things with GraphQL:

  • create a GraphQL server
  • consume a GraphQL server, either through a HTTP call or using a client like Apollo or Relay or any of the either multitude of clients available out there

What concepts do I need to know about

There are some concepts being thrown around with GraphQL but really there isn't much to learning to use it:

  • Schema, this is the schema definition and pretty much describes the data structure the client can query, think of it as a database schema
  • Query, this is a question that returns a response
  • mutation, this looks like a question but CREATES, DELETES or UPDATES usually
  • Mutation, this function that will change something with your backend, compare it to an INSERT, UPDATE or DELETE
  • Resolver, this is a function that responds to something you are trying to do, it is part of your schema definition. Regardless of wether it's a query or mutation, it needs to have a resolver function that says "this is what's gonna happen if you invoke me"

results matching ""

    No results matching ""