Skip to content

Instantly share code, notes, and snippets.

@djaoka
Created September 5, 2016 21:16
Show Gist options
  • Save djaoka/3857010398b9339d9b238cc691b55dbf to your computer and use it in GitHub Desktop.
Save djaoka/3857010398b9339d9b238cc691b55dbf to your computer and use it in GitHub Desktop.
import {
graphql,
GraphQLSchema,
GraphQLObjectType,
GraphQLString
} from 'graphql';
var schema = new GraphQLSchema({
query: new GraphQLObjectType({
name: 'RootQueryType',
fields: {
hello: {
type: GraphQLString,
resolve() {
return 'world';
}
}
}
})
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment