Created
September 26, 2018 11:32
-
-
Save arbaouimehdi/8cde5225c6cead2b8066f78b393f448f to your computer and use it in GitHub Desktop.
Graphcool types
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# The following types define the data model of the example service | |
# based on which the GraphQL API is generated | |
type User @model { | |
id: ID! @isUnique | |
name: String | |
dateOfBirth: DateTime | |
# Uncomment below - you can declare relations between models like this | |
# posts: [Post!]! @relation(name: "UserPosts") | |
} | |
# Uncomment the model below as well | |
# type Post @model { | |
# id: ID! @isUnique | |
# title: String! | |
# | |
# # Every relation also required a back-relation (to determine 1:1, 1:n or n:m) | |
# author: User! @relation(name: "UserPosts") | |
# } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment