ricardo-valero / roc-gql

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

roc-gql

[WIP] GraphQL in Roc experiment. Far from spec-compliant.

Example

  1. Run the server:
$ roc examples/posts.roc
  1. Point your prefered GraphQL playground app (such as Altair) to http://localhost:8000 and run a query!

Example query

query {
  posts {
    ...PostBasics
  }

  postNumberOne: post(id: 1) {
    ...PostBasics
    body
    author {
      firstName
      lastName
    }
  }
}

fragment PostBasics on Post {
  id
  title
  section
}

About