This Project is my implementation of how to graphql course for Node.js and Prisma based on graphql-yoga and prisma.
Clone the repository:
git clone https://github.com/Lazhari/hacker-news-api.git
Install Node dependencies
cd hacker-news-api
yarn
To run the server, you need the Prisma CLI. Please install it via NPM
npm install -g prisma
prisma deploy
Launch your GraphQL server with this command:
npm run start
docker-compose run api prisma deploy
docker-compose up
When you update your prisma models, you need to deploy that to prisma. Then you can run this command:
docker-compose exec api prisma deploy
Navigate to http://localhost:4000 in your browser to explore the API of you GraphQL server in a GraphQL Playground.