Executing Schema-First Systems
We have already learned a lot throughout this book, so it’s time to do something that will work both on the backend and frontend. In this chapter, we will learn how to design a schema and implement it using TypeScript and a Node.js backend for a Questions and Answers system. This app will be built on a GraphQL schema, work with a MongoDB database, and include a username-password authentication system.
Just using GraphQL Schema Definition Language to describe a system isn’t very useful. To make full use of GraphQL and this schema-driven software, you need to code a GraphQL server. To do this, we need to provide resolver functions for GraphQL-type fields, which can be done by writing the backend server for the GraphQL schema.
In this chapter, we will cover the following topics:
- Setting up our project
- Creating the schema
- Connecting a database schema and a type system
- Handling user authorization and authentication ...