Skip to content

sohan2410/linkize-social-media-application

Repository files navigation

Welcome to Linkize 👋

Version License: ISC

Social Media Application

Project Description

Social media application for webkriti.

  • Users can create their account in our database and sign in or directly sign in through google authentication.
  • Once the user is successfully signed in, they will be redirected to the complete their profile page to fill in other necessary details.
  • The user can see every post posted by other users on their home page and can like them.
  • The home page also contains an option to post their thoughts (post) with an image.
  • Also, there are rooms made for users to chat about topics with everyone online in the community.
  • Also, other users can be searched, and the user can view that user's profile.
  • Users can also send us feedback that will be mailed to us.
  • Lastly, a view profile page exists wherein users can see all their posts, delete them, or even update.
  • We have also added light and dark modes for user's viewing comfort.

Screen shots

Features Implemented

Front-end

  1. Landing page:
  • The landing page contains the overview of the website about how we intend the users to use this website.
  1. Sign in and sign up page :
  • All the checks have been made on the frontend side for email and password. For example, we have defined the password pattern that the user must enter while signing up.
  1. Feed Page :
  • Once the user is signed in, a token is generated, saved in local storage, which helps maintain session activity. This token is verified every time the user visits any page. Users can also upload a post with an image, and this image is compressed on the frontend side and stored in a database. Like feature has also been added wherein users can like posts. Users can also search other Linkize users and can then click on their names to view their profiles. Feedback by users is also added, and then the feedback is mailed to Linkize email.
  1. Chat Rooms :
  • Chat rooms have also been implemented using socket.io. When someone joins a chat, a notification is sent in the room that the particular user has joined the chat. Also, the user is typing feature has also been implemented to know which user is currently typing.
  1. View Profile Page :
  • Users can make changes to their profile like their profile image, bio, DOB, etc., and all this information is sent to the back-end and then further stored in the database.
  1. Edit Profile Page :
  • Users can make changes to their profile like their profile image, bio, DOB, etc., and all this information is sent to the back-end and then further stored in the database.
  1. Other features :
  • Light-dark mode: These modes are also implemented in the website for user's eye comfort. Once the user switches on to the other mode, all the other pages that the user navigates to will be in the same mode.
  1. 404 page :
  • If the user navigates to a route that does not exist, a 404 error page is displayed, and the user can then be redirected to the homepage.

Back-end

  1. Routes for authentication purpose
  • We have setup basic authentication & also implemented google & facebook passport strategy
  • Currently facebook auth is working locally but giving issues on deployed website
/auth/signin
/auth/signup
/auth/google
/auth/facebook
  1. Details route to get, update, view or search other profiles
/details/getdetails
/profile/:userid
/search
  1. Feedback route to send mail to us using node mailer
/feedback/sendmail
  1. Posts route to create a new post, get all posts, update / dislike post, update / delete post
  • We are verifying token as middleware for every post, put, update or delete request
/posts/createnewpost
/posts/getallposts
/posts/updatelike/:postid
/posts/updateddislike/:postid
/posts/updatepost/:postid
/posts/deletepost/:postid
/posts/profile/:username
/posts/getpics
  1. Rooms
  • By this user can join room by verify token & to send name, userid to socket connection
/rooms/joinroom

Technologies/Libraries/Packages Used

Packages README
bcrypt To store hashed password in database
dotenv To keep db connection string, client id, client secret key safe
image-to-base64 To convert images of posts or image url to base 64 & storing in database
jsonwebtoken To store users session encrypted and verify them as middleware in posts/details/feedback api request
moment-timezone To handle time zone and send in socket connection
nodemailer To send feedback to our mail
nodemon To run application in dev mode
passport-facebook Facebook authentication
passport-google-oauth20 Google authentication
pg To Connect to AWS RDS
socket.io To enables realtime, bi-directional communication between web clients and servers.

Local Setup

  1. To run the server in dev mode use
    npm run dev
  2. To run the server in production mode
    npm start 
  3. Note that database connection string, passport client id & secret keys are in env file which are not uploaded on github

Built With

html5css3javascriptnodejspostgresql express

Contact

👤 Sohan Bandary, Swahim Namdev, Ranjith Jupaka

Sohan Bandary (2020IMG-016)

Swahim Namdev (2020IMG-063)

Ranjith Jupaka (2020IMT-042)

Show your support

Give a ⭐️ if this project helped you!