- I deployed the project on netlify.
- Link
Note: for database structure and Approach
Postgram is a discussion forum where you can post and discuss anonymously with anyone.
- Motive to develop this app is to allow users to express their thoughts without any fear.
- I learned about how to manage RDBMS and fetching proper queries from database.
- Clone the repo.
- Using
npm installinstall all dependencies. - Start development server
npm run start
- Authentication
- Project Mangement
- Drag and drop feature to change status of task.
- Mutliple role
- OTP Authentication
- Create post
- Comment on post
- View all post
- User
| Attribute | Type |
|---|---|
| Name | String |
| Email(unique) | String |
- OTP
| Attribute | Type |
|---|---|
| Email(unique) | String |
| otp | String |
It is used to verify email address and it get deleted after 5 minutes from creation.
- Post
| Attribute | Type |
|---|---|
| _id | String |
| Author_id | String |
| Title | String |
| Body | String |
| Comment_Count | Number |
| Reply_Count | Number |
Author_id is referenced to Email of User
- Comment
| Attribute | Type |
|---|---|
| _id | String |
| Author_id | String |
| Post_id | String |
| Body | String |
Author_id is referenced to Email of User Post_id is referenced to _id of Post
- Reply
| Attribute | Type |
|---|---|
| _id | String |
| Author_id | String |
| Post_id | String |
| Comment_id | String |
| Body | String |
Author_id is referenced to Email of User Post_id is referenced to _id of Post Comment_id is referenced to _id of Comment
- Used axios library to interact with APIs.
- login
- Takes email as input data and verifies the user.
- signup
- Takes email and username as input data and creates an account for user.
- sendotp
- Takes email as input and sends and otp which is verified in login and signup API to verify emails.
- GetAllPostList
- To get all post from every user.
- GetPostList
- TO get only your posts.
- CreatePost
- TO create a new post.
- GetPost
- To get a specific post using post_id.
- AddComment
- To add a comment on a post
- AddReply
- To add a reply on a comment of a post.