Skip to content

Instantly share code, notes, and snippets.

@nicolasdao
Created August 7, 2017 12:20
Show Gist options
  • Save nicolasdao/dd6389fdd13a17e498bcb27310d9765e to your computer and use it in GitHub Desktop.
Save nicolasdao/dd6389fdd13a17e498bcb27310d9765e to your computer and use it in GitHub Desktop.
const schema = `
type Teacher {
id: ID!
creationDate: String
firstname: String!
middlename: String
lastname: String!
age: Int!
gender: String
title: String!
}
type Student {
id: ID!
creationDate: String
firstname: String!
middlename: String
lastname: String!
age: Int!
gender: String
nickname: String!
questions: Questions
}
type Question {
id: ID!
creationDate: String
name: String!
text: String!
}
type Teachers {
data: [Teacher]
cursor: ID
}
type Students {
data: [Student]
cursor: ID
}
type Questions {
data: [Question]
cursor: ID
}
type Query {
# ### GET all users
#
students: Students
# ### GET all teachers
#
teachers: Teachers
}
`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment