1. WHAT IS GRAPHQL

§ This post is written for personal study purposes § 
§ This post may include contents from Learning GraphQL : Declarative Data Fetching for Modern Web Apps §

What is GraphQL

GraphQL is a query language for APIs. It is typically served over HTTP. GraphQL queries ask for only the things they need and the server returns those queried rather than returning fields that are programmed.
Typically with REST, when the client needs different set of data, you either need to make a new endpoint for that specific need or return a huge sized data that can serve different purposes. However, with GraphQL, client is able to query only the data that it needs(Underfetching).

Design Principles of GraphQL

  1. Hierarchical : Fields are nested and query is shaped like the data it returns.
  2. Product Centric : GraphQL is driven by the data needs of the client.
  3. Strong Typing : Each data point has specific type and is validated.
  4. Client-specific queries
  5. Introspective : queries

댓글

이 블로그의 인기 게시물

[Django 공식문서 번역] REST Framework - Viewset and Router

[Django REST Framework] create() vs perform_create()

Intel Open WebRTC Toolkit(OWT) Media server 설치하는법