Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
// src/index.js
const { GraphQLServer } = require('graphql-yoga')
const { prisma } = require('../prisma/generated/prisma-client')
const server = new GraphQLServer({
typeDefs: './src/schema.graphql', // IMPORT our schema.graphql
context: request => {
return {
server.start(() => console.log(`Server is running on http://localhost:4000`))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.