Features
- Login
- Register
- CRUD a todo (Need login to CUD)
What used
Back-end : Node.js, Express.js
Data fetching : GraphQL, Mongoose
Authentication : JWT
Pre-work
- MongoDB and Node.js must be installed in your computer.
- MongoDB must be run in your computer.
How to run
- Clone or download project
- Go to the project directory in command prompt
- Install dependencies -> "npm install"
- Run app -> "DEBUG=/:* npm start"
- Load "localhost:3001" in web browser
You can go to url : localhost:3001/graphql to test graphql api
GraphQL queries and mutations
Web endpoint
- /graphql
- GraphQL Page - Test queries and mutations
Mongoose Schema
- User - id(_id) - password - email - name
- Todo - id(_id) - user_id - title - completed - createdAt