Byekibe / GraphQL

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Graphql

Graphql is a query language for APIs and a runtime for fulfilling those queries with your existing data. Graphql provides a complete and understandable description of your data in your API, gives clients the power to ask for exactly what they need and nothing more, makes it easier to evolve APIs over time, and enable powerful developer tools. At its core, GraphQL enables declarative data fetching. Instead of multiple endpoints that return fixed data structures, a GraphQL server only exposes a single endpoint and responds precisely with the data a client asked for.

Core Concepts

At the core of every GraphQL API, there is a GraphQL schema. Graphql schemas are usually written in Schema Definition Language. Every GraphQl schema has three special root types:

  • Query
  • Mutation
  • Subscription

express-Graphql

express-graphql module provides a simple way to create an Express server that runs on GraphQL API. SDL has a type system that allows you to define data structures.

Setting up express server

GraphiQL Tool

References:

  1. express-graphql-Docs

About


Languages

Language:JavaScript 96.5%Language:CSS 2.1%Language:HTML 1.4%