Giter Club home page Giter Club logo

fakebooker-backend's Introduction

Hi there ๐Ÿ‘‹

fakebooker-backend's People

Contributors

404kacper avatar dependabot[bot] avatar kristianweb avatar letsgitcracking avatar quincyhill avatar rohitkrishna094 avatar williamj1788 avatar zihadmahiuddin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

fakebooker-backend's Issues

#2 Implement Notification system: post notifications

Is your feature request related to a problem? Please describe.
We need to implement a notification system for our app and we are starting off with posts notifications. The issue should implement the following features:

2. User liked your post
You need to utilize web sockets for achieving that by using GraphQL subscriptions.

You can work on this feature by creating and using a branch called feature/notification-system

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#1 Integrate GraphQL ( Migrate from REST to GraphQL )

Is your feature request related to a problem? Please describe.
We've decided to migrate our backend architecture from REST API based to GraphQL based since we can handle data better without having to make 120 endpoints. We're starting off with integrating graphql to our existing project using apollo-server-express.

Describe the solution you'd like
For our backend we are gonna use Apollo Server Graphql implementation ( it's got a good ecosystem, more features like advanced caching & better error handling and debugging + there are more people that use which is good )

1. Install packages:

yarn install graphql apollo-server-express --save

Note that we are gonna be using apollo-server-express so we can apply our express code as a middleware and have access to the server core.

2. Integrate graphql with apollo-server-express

Detailed resource on how you do it you can find in here

You will work on this feature by creating and using a branch called feature/apollographql-integration

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Change code from running on local env to our hosting solutions ( heroku )

Simply setup the app to run on heroku instead of localhost.

You can work on this feature by creating and using a branch called feature/heroku-deploy

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

About section: Profile Page

Is your feature request related to a problem? Please describe.
We are going to implement an About section that is going to be used for entering and editing personal data.

Describe the solution you'd like
Create more personal fields in the User Model:

  • workPlace ( work as )
  • homePlace ( lives in )
  • birthPlace ( from )

You can work on this feature by creating and using a branch called feature/about-user

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Add Comment Model

Is your feature request related to a problem? Please describe.
Create Comment.js in models folder. We will need to create the below model and export it as mongoose model from this file.

{
	id: String, // ObjectId of the comment
	userId: String, // ObjectId of the user
	content: String, // actual content of the comment
	creationDate: Number, // unix timestamp of when this comment was created
	likedBy: [{
		id: String, // ObjectId of the user,
	}], // array of users who liked this comment
	disLikedBy: [{
		id: String, // ObjectId of the user,
	}], // array of users who disliked this comment
	edited: boolean,
	lastEditedDate: Number, // unix timestamp lastEdited
}

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Notification System

Is your feature request related to a problem? Please describe.
We are going to implement a notification system that's going to be used for notifying related data between users.
Untitled
Describe the solution you'd like
When User A comments on User B's post we have to store a notification model in DB.

  • Create the notification model ( Mongoose )
  • Think and assign actions corresponding to actionTypes:
    • 1 comment on a post
    • 2 like a post
  • When User A comments on User B's post create a notification
  • Create a notification message and return it to the user
  • When User A comments on User B's post but after that deletes his comment => delete the notification
  • When User A likes User B's post but after the unlikes it => delete the notification ( if he likes back add it again )
  • GraphQL subscriptions [ when a notification is created ]
  • GraphQL subscriptions [ when a notification is deleted ]

The notification system is implemented but there are few refactors that are going to be implemented:

  • Resolvers deleteComment/createComment return a different type ( the Comment model and not the Post model ). Check that on the frontend and see if there are errors and also refactor the type they are returning ( more info on the comment I've written in the code ).
  • Update all backend GraphQL testing queries to contain only the data you need and not the whole Post model

You can work on this feature by creating and using a branch called feature/notification-system

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#2 Migrate register functionality ( Migrate Authentication from REST to GraphQL )

Is your feature request related to a problem? Please describe.
For our authentication layer we're starting off with migrating register function located in routes/auth.js.

Describe the solution you'd like
1. Create a graphql structure that's gonna look like this: Resource

2. Use the resource for reference on how to migrate the register function. Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

You will work on this feature by creating and using a branch called feature/register-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update createComment types/mutations

Is your feature request related to a problem? Please describe.
We have to update the Comment GraphQL architecture:

Describe the solution you'd like:

  • Update typeDefs createComment/Comment
  • Update users.js/comments CreateComment mutation
  • Test the feature by creating a comment under a post that should now include the new User's properties.

You can work on this feature by creating and using a branch called feature/update-createComment

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Add Post Model

Is your feature request related to a problem? Please describe.
We need to add post mongoose model. This model relates to posts that are made by users in our system.

Describe the solution you'd like

  1. In the models folder create a new file post.js
  2. Then create and export a mongoose model called Post.
  3. The model could have properties like this:
{
    id: String, // ObjectId of post
    source: String, // ObjectId of person who made the post
    destination: String, // ObjectId of person who received the post(whose wall?)
    typeOfPost: String, // Type of post[i.e., text, image, url like reddit?]
    content: String, // actual content of the post
    creationDate: Number, // unix timestamp of when this post was created
    likesCount: Number, // numer of current likes
    dislikesCount: Number, // numer of current dislikes
    likedBy: [{
        id: String, // ObjectId of the user,
        username: String,
        displayName: String,
        profileImage: String, // so that we can show small image
    }], // array of users who liked this post
    disLikedBy: [{
        id: String, // ObjectId of the user,
        username: String,
        displayName: String,
        profileImage: String, // so that we can show small image
    }], // array of users who disliked this post
    comments: [Comment], // array of comments
    edited: boolean,
    lastEditedDate: Number, // unix timestamp lastEdited
}

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Remove the old REST code

Is your feature request related to a problem? Please describe.
We need to remove the old REST code because it got replaced by GraphQL.

You should do this issue after you migrate the Posts REST API #55 #56. Until that you can use the code as a reference for faster implementation.

You can work on this issue by creating and using a branch called feature/remove-rest

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#1 Implement a Liking system ( Displaying Likes ) for our Posts GraphQL API

Is your feature request related to a problem? Please describe.
We have to implement a liking system that's going to be used for our Posts GraphQL API ( Comments included but later ).

You should work on this feature only if you've implemented the creating likes functionality

Describe the solution you'd like
Use this whole tutorial for reference on how to implement displaying likes functionality. Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

You will work on this feature by creating and using a branch called feature/likes-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update register route endpoint

Is your feature request related to a problem? Please describe.

We need to update the register endpoint with the new fields so the User will include: email, username, password, fullName, dateOfBirth, gender

Describe the solution you'd like

  1. In routes folder, we already have auth.js file
  2. Add more fields such as these to this route endpoint.

Keep in mind that this code is just for reference how the user is being stored, do not straight copy/paste

  const newUser = new User({
    email: req.body.email,
    username: req.body.username,
    password: req.body.password,
    fullname: req.body.fullName,
    dateOfBirth: req.body.dateOfBirth,
    gender: req.body.gender
  });

You can work on this feature using a branch called feature/auth-register-update.

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Post system: Images, Markdown ( Cloudinary, React-Markdown )

Is your feature request related to a problem? Please describe.
The Post system right now only contains text feature but to be able to have photos in our profile pages we have to add an image feature:

Describe the solution you'd like

  • Save Cloudinary url to image DB property
  • add image url only when you provide it in the mutation createPost which shouldn't be required
  • update typeDefs / mutations and add a type param
  • Markdown is going to be saved as a string in the body property, nothing has to be changed

You can work on this feature by creating and using a branch called feature/post-image

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Add Comment Model

Is your feature request related to a problem? Please describe.
We need to add comment mongoose model. This comment relates to the comments on posts(which users can make in our system).

Describe the solution you'd like

  1. In the models folder create a new file comment.js
  2. Then create and export a mongoose model called Comment.
  3. The model could have properties like this:
{
    id: String, // ObjectId of the comment
    postId: String, // ObjectId i.e., postId where this comment comes from
    user: {
        id: String, // ObjectId of the user
        username: String,
        displayName: String,
        profileImage: String,
    }, // user who made this comment
    content: String, // actual content of the comment
    creationDate: Number, // unix timestamp of when this comment was created
    likesCount: Number, // numer of current likes
    dislikesCount: Number, // numer of current dislikes
    likedBy: [{
        id: String, // ObjectId of the user,
        username: String,
        displayName: String,
        profileImage: String, // so that we can show small image
    }], // array of users who liked this comment
    disLikedBy: [{
        id: String, // ObjectId of the user,
        username: String,
        displayName: String,
        profileImage: String, // so that we can show small image
    }], // array of users who disliked this comment
    edited: boolean,
    lastEditedDate: Number, // unix timestamp lastEdited
}

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update User Model with more fields regarding personal data

Is your feature request related to a problem? Please describe.
We want to add more fields to user model regarding personal data ( needed for the About UI Component ) and also remove the displayName and use the fullName from the new fields.

Describe the solution you'd like

  1. In models folder, we already have User.js file
  2. Add more fields such as these to this mongoose model.
{
     firstName: { type: String, required: true },
     lastName: { type: String, required: true },
     dateOfBirth: { type: Number, required: true },
     gender: { type: String, required: true }
}
  1. Update the displayName property because it's value is actually the first string of the email ( kristian of [email protected] ) which is not a good idea since the email names are completely random ( thewinners12@ one of my emails for example ). Instead we can use the firstName field.

Personal proposition
4) I don't think we need to have a username field in the Register UI simply because it's useless to ask this at first point. My proposition is to use facebook's way of doing it:

      1) The facebook's register form asks for fullname, phone, password, birthOfDate and gender. 
      
      2) When the account is created a unique username is created using the fullname and some 
          random digits after it and then if you want to change the username you can do so in the 
          user settings.

You can work on this feature using a branch called feature/user-update-model.

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Newsfeed system

Is your feature request related to a problem? Please describe.
The newsfeed system is essentially going to be fetching all posts from all the users in the application in a specific way.

Describe the solution you'd like

  • Fetch all posts sorted by createdAt.
  • Newsfeed should be real-time => GraphQL subscriptions

You can work on this feature by creating and using a branch called feature/newsfeed

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Friends System

Is your feature request related to a problem? Please describe.
The user should be able to have friends. Consider the following DB relations:
Friends system

Describe the solution you'd like
When User A send friend request to User B ( by clicking a button on the frontend ) it will take the ID of the userA ( requester ) who sent it, ID of userB ( recipient ):

  • Create a new field status in the notification Model
  • Status will be pending, accepted, rejected
  • When User A sends a friend request to user B => create a notification with status pending
  • If the user B accepts then status will be accepted => add User A's id to user B's friends array DB
  • If user B rejects=> status "rejected" => notifications gets deleted ( without notifying )

You can work on this feature by creating and using a branch called feature/friends-system

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update Register GraphQL types/mutations

Is your feature request related to a problem? Please describe.
We have to update the Register GraphQL architecture:

You should work on this issue once you've implemented #47

Describe the solution you'd like:

  • Update typeDefs register
  • Update users.js/register mutation
  • Update generateToken func
  • Test the feature by creating a user that should be successfully added to the DB

You can work on this feature by creating and using a branch called feature/update-register

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update LoadUser GraphQL types/queries

Is your feature request related to a problem? Please describe.
We have to update the loadUser GraphQL architecture:

You should work on this issue once you've implemented #47

Describe the solution you'd like:

  • Update users.js/loadUser query
  • Update generateToken func
  • Test the feature by loading a user using a jwt token after register

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#4 Migrate loadUser functionality ( Migrate Authentication from REST to GraphQL )

Is your feature request related to a problem? Please describe.
We need to migrate the loadUser function located in routes/auth.js.

Describe the solution you'd like
1. Use the same structure that's described in details in other issues ( #50 ).

2 You can test if the implementation works by running the project locally ( a graphql playground is provided by apollo-server-express ) and see if everything is alright. If you encounter any problems regarding figuring that out ask the other developers in the discord server.

You will work on this feature by creating and using a branch called feature/loaduser-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Comment system: Like, Reply

Is your feature request related to a problem? Please describe.
Comemnts for now can only be viewed/removed and nothing else. We are going to implement liking and replying functionality on them:

Describe the solution you'd like
Like a comment:

  • Change Like model postId ref to dynamic refPath and include the needed model in a specific situation ( Comment when we like a comment or Post when we like a post )
  • likeComment resolvers/types
  • we should be able to like a comment

Reply to a comment:

  • Create a CommentReply Model
    Untitled

  • commentReply resolvers/types

  • Store commentReply ID in the comment

  • We should be able to reply to a comment

Try to fetch the likes and comments without storing their IDs in the Post since I think that it's easier. Try it out!!

You can work on this feature by creating and using a branch called feature/comment-update

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Deploy NodeJS/MongoDB App

Is your feature request related to a problem? Please describe.
We have to see available hosting options for deploying our backend app.

  • Check available options
  • Pick the best one
  • Deploy

You can work on this feature by creating and using a branch called feature/deploy

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Migrate from apollo-server-express to apollo-server

Is your feature request related to a problem? Please describe.
We need to migrate to apollo-server because we are having problems with suscriptions implementation.

You can work on this feature by creating and using a branch called feature/apollo-server-migration

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update deletePost GraphQL types/mutations

Is your feature request related to a problem? Please describe.
We have to update the Post GraphQL architecture:

Describe the solution you'd like:

  • Update typeDefs deletePost/Post
  • Update users.js/posts deletePost mutation
  • Test the feature by deleting a post that should now include the new User's properties.

You can work on this feature by creating and using a branch called feature/update-deletePost

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update createPost GraphQL types/mutations

Is your feature request related to a problem? Please describe.
We have to update the Post GraphQL architecture:

Describe the solution you'd like:

  • Update typeDefs CreatePost/Post
  • Update users.js/posts CreatePost mutation
  • Test the feature by creating a post that should now include the new User's properties.

You can work on this feature by creating and using a branch called feature/update-createPost

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

changeAvatarImage/changeCoverImage mutation

Is your feature request related to a problem? Please describe.

  • Implement changeAvatarImage / coverImage mutation for when the user wants to change his avatar when entering his profile page.

You can work on this feature by creating and using a branch called feature/change-image

Update deleteComment types/mutations

Is your feature request related to a problem? Please describe.
We have to update the Comment GraphQL architecture:

Describe the solution you'd like:

  • Update typeDefs deleteComment/Comment
  • Update users.js/comments deleteComment mutation
  • Test the feature by deleting a comment under a post that should now include the new User's properties.

You can work on this feature by creating and using a branch called feature/update-deleteComment

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#1 Migrate Posts ( GET Requests ) to GraphQL ( Migrate Posts API from REST to GraphQL )

Is your feature request related to a problem? Please describe.
For our Posts API we're starting off with migrating displaying posts functionality located in routes/posts.js.

Describe the solution you'd like
Use the resource for reference on how to migrate getting posts functionality. Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

You will work on this feature by creating and using a branch called feature/posts-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#1 Implement Notification system: post notifications

Is your feature request related to a problem? Please describe.
We need to implement a notification system for our app and we are starting off with posts notifications. The issue should implement the following features:

1. User commented on your post
You need to utilize web sockets for achieving that by using GraphQL subscriptions.

You can work on this feature by creating and using a branch called feature/notification-system

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Chat system

Is your feature request related to a problem? Please describe.
A very interesting feature that I'm personally excited about is developing a chat system:
Untitled

Describe the solution you'd like
Use the following resources to guide you through your coding journey:

You can work on this feature by creating and using a branch called feature/chat-system

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Implement the detailed personal form

Is your feature request related to a problem? Please describe.

We have the about component with a detailed form modal which is used by the user to fill his personal data about himself. Implement a backend function called `personalData which populates the User model's properties.

Describe the solution you'd like
Implement a new function located in routes/auth.js that will be hit from the frontend with the user's data. Use the information and populate the existing properties in the User.js model.

You can work on this feature by creating and using a branch called feature/personal-data

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

getMessages Query

Is your feature request related to a problem? Please describe.

  • Currently the getMessages query returns all messages related to the authUser ( notifier ) which means that every message ( even from the same user ) is shown on the frontend. Implement logic that returns the latest message from every single thread in an array.

You can work on this refactor by creating and using a branch called refactor/get-messages

Unit Testing Node ( IMPORTANT )

Is your feature request related to a problem? Please describe.
Before implementing all these new features ( issues ) let's make sure we do that the right RIGHT way! We are going to be using a lot of good techniques ( TDD etc. ) for test-covering our app so we can sleep good at night without having nightmares.

Describe the solution you'd like

  • Add new dependencies to the project: jest
  • Follow the jest docs for setting it up

You may ask why do I have to test this app at all when it's not going to hit any audience and it's probably going to be used only in my portfolio. Well, I don't think that the customers of any app are the cause for testing it. In my opinion the good and professional code is the one that's well tested, documented and error-prone! Also it's really cool to test new things and see how they work.

You can work on this feature by creating and using a branch called feature/unit-testing

#2 Migrate Posts ( Post Requests ) to GraphQL ( Migrate Posts API from REST to GraphQL )

Is your feature request related to a problem? Please describe.
In this issue we are gonna be migrating creating posts functionality located in routes/posts.js.

Describe the solution you'd like
Use the resource for reference on how to migrate creating posts functionality. Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

You will work on this feature by creating and using a branch called feature/posts-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

newMessage Subscription

Is your feature request related to a problem? Please describe.

  • Right now the newMessage subscription doesn't have a backend check whether the user is the notifier that the message is being sent to. That means that newMessage subscription is being broadcasted to every user on the app and then with frontend logic its filtered out to creator/notifier which is really complex on the frontend and not needed. Refactor newMessage to check that on the backend instead on the frontend.

You can work on this refactor by creating and using a branch called refactor/new-message

Update Post system: Comments, Likes, general refactoring

Is your feature request related to a problem? Please describe.
The like system and the Post one are now separated from each other, you have to separate the Comments as well.

Describe the solution you'd like:

  • Move them into a separate Model file
  • Adding comments on a Post should only include commentIds on the Post model and a postId on the comment Model.
  • Update post's author property to userId
  • Split likes resolvers into a separate file

Consider the following schema:
Post system

You can work on this feature by creating and using a branch called feature/update-commentModel

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

shortDescription mutation

Is your feature request related to a problem? Please describe.

  • Add property quotes to User model
  • Implement shortDescription mutation for when the user wants to add personal quotes to his profile page

You can work on this feature by creating and using a branch called feature/short-description

#3 Migrate login functionality ( Migrate Authentication from REST to GraphQL )

Is your feature request related to a problem? Please describe.
We need to migrate the login function located in routes/auth.js.

Describe the solution you'd like
1. Create a graphql structure that's gonna look like this: Resource

2 Use the resource for reference on how to migrate the register function. Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

3 You can test if the implementation works by running the project locally ( a graphql playground is provided by apollo-server-express ) and see if everything is alright. If you encounter any problems regarding figuring that out ask the other developers in the discord server.

You will work on this feature by creating and using a branch called feature/login-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

deletePost mutation

Is your feature request related to a problem? Please describe.

  • When you delete a post, make sure to delete all comments/likes related to it.

  • Also since you are the post creator you should be able to delete other people comments if necessary.

You can work on this refactor by creating and using a branch called refactor/post

Update GraphQL getPosts types/queries

Is your feature request related to a problem? Please describe.
We have to update the Post GraphQL architecture:

Describe the solution you'd like:

  • Update typeDefs getPosts
  • Update users.js/posts getPosts query
  • Test the feature by fetching created posts and they should include the new user's properties.

You can work on this feature by creating and using a branch called feature/update-getPosts

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update likePost GraphQL types/mutations

Is your feature request related to a problem? Please describe.
We have to update the Post GraphQL architecture:

Describe the solution you'd like:

  • Update typeDefs likePost/Post
  • Update users.js/posts likePost mutation
  • Test the feature by liking a post.

You can work on this feature by creating and using a branch called feature/update-likePost

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Implement deleting posts ( GraphQL )

Is your feature request related to a problem? Please describe.
We have to implement deleting posts functionality for our Posts GraphQL API.

Describe the solution you'd like
Use this whole tutorial for reference on how to implement deleting posts functionality. Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

You will work on this feature by creating and using a branch called feature/posts-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update Post Model

Is your feature request related to a problem? Please describe.
Update Post.js in models folder. We will need to create the below model and export it as mongoose model from this file.

{
    source: String, // ObjectId of person who made the post
    destination: String, // ObjectId of person who received the post(whose wall?)
    typeOfPost: String, // Type of post[i.e., text, image, url like reddit?]
    content: String, // actual content of the post
    creationDate: Number, // unix timestamp of when this post was created
    likedBy: [{
        id: String, // ObjectId of the user,
    }], // array of users who liked this post
    disLikedBy: [{
        id: String, // ObjectId of the user,
    }], // array of users who disliked this post
    edited: boolean,
    lastEditedDate: Number, // unix timestamp lastEdited
    comments: [Comment], // array of comments
}

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update User Model with more properties

Is your feature request related to a problem? Please describe.
We want to add more fields to user model.

Describe the solution you'd like

  1. In models folder, we already have user.js file
  2. Add more fields such as these to this mongoose model.
{
    email: String, // unique in the entire application
    displayName: String, // no need to be unique
    profileImage: String, // to be decided most likely base64 img or blob
    coverImage: String, // to be decided most likely base64 img or blob
    photos: Array[byte] // array of top 9 base64 images,
    joinDate: Number, // unix timestamp
    lastLogin Number, // unix timestamp
    status: {
        isActive: boolean,
        lastActiveDate: Number, // unix timestamp
    }
    about: {
        dob: Number, // unix timestamp for date of birth,
        bio: String, // their bio or description
    }, // about section
}

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#1 Implement a Liking system ( Creating Likes ) for our Posts GraphQL API

Is your feature request related to a problem? Please describe.
We have to implement a liking system that's going to be used for our Posts GraphQL API ( Comments included but later ).

You should work on this feature only if you've implemented the deleting post functionality

Describe the solution you'd like
Use this whole tutorial for reference on how to implement creating likes functionality. Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

You will work on this feature by creating and using a branch called feature/likes-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#1 Implement a Comment system ( Creating Comments ) for our Posts GraphQL API

Is your feature request related to a problem? Please describe.
We have to implement a comment system that's going to be used for our Posts GraphQL API.

You should work on this feature only if you've implemented the Posts GraphQL migration

Describe the solution you'd like
Use this whole tutorial for reference on how to implement creating comments functionality Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

You will work on this feature by creating and using a branch called feature/comments-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Migrate to TypeScript

Is your feature request related to a problem? Please describe.
The moment has come and that is a perfect time to integrate TypeScript!

Describe the solution you'd like

  • Add ts packages and tsconfig ( set-up TypeScript )
  • Migrate the backend code

Helpers:
Express/Apollo/GraphQL/TypeScript Project article
Project repo

You can work on this feature by creating and using a branch called feature/typescript

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. npm test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Update User Model with more fields regarding personal data

Is your feature request related to a problem? Please describe.
We want to add more fields to user model regarding personal data ( needed for the detailed form on the about component )

Describe the solution you'd like

  • The User model should have the following properties: firstName, lastName, email, password, gender, avatarImage, coverImage, roles
  • Use other default links as coverImage and avatarImage ( find an image really similar to facebook )
  • Remove User properties that are not needed ( posts, about, status etc. ). If we need it later we will add them back in the future

You can work on this feature using a branch called feature/user-update-model.

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn test doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

#2 Implement a Comment system ( Displaying Comments ) for our Posts GraphQL API

Is your feature request related to a problem? Please describe.
We have to implement a comment system that's going to be used for our Posts GraphQL API.

You should work on this feature only if you've implemented the Posts GraphQL migration

Describe the solution you'd like
Use this whole tutorial for reference on how to implement displaying comments functionality Just make sure you adjust that code and use it in our app ( don't straight copy/paste please! )

You will work on this feature by creating and using a branch called feature/comments-graphql-implementation

Pull Request Squashing

Please, go through these steps before you submit a PR.

  1. Make sure that your PR is not a duplicate.
  2. If not, then make sure that:

2.1. You have done your changes in a separate branch. Branches MUST have descriptive names that start with either the fix/ or feature/ prefixes. Good examples are: fix/signin-issue or feature/issue-templates.

2.2. You have a descriptive commit message with a short title (first line).

2.3. You have only one commit (if not, squash them into one commit).

2.4. yarn run lint doesn't throw any error. If it does, fix them first and amend your commit (git commit --amend).

  1. After these steps, you're ready to open a pull request.

3.1. Give a descriptive title to your PR.

3.2. Provide a description of your changes.

3.3. Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.