Git Product home page Git Product logo

dsrathore1 / social-media Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 5.48 MB

Connect and share seamlessly with our Social Media App, a MERN stack-powered platform offering secure authentication, real-time updates, and interactive features for creating, liking, and commenting on posts.

License: MIT License

JavaScript 99.44% CSS 0.56%
cicd docker javascript monorepo nextjs nginx nodjs npm-package reactjs typescript

social-media's Introduction

Social Media App

Table of Contents

Description

This is a full-stack Social Media App built using the MERN (MongoDB, Express.js, React.js, Node.js) stack. It allows users to connect, share posts, and engage in social interactions. The application provides a seamless and responsive user interface, making it easy for users to navigate and interact with each other.

Features

  • User Authentication: Secure user authentication using JWT (JSON Web Tokens).
  • User Profiles: Users can create and customize their profiles.
  • Post Creation: Users can create and share posts with text, images, or links.
  • Like and Comment: Users can interact with posts by liking and commenting on them.
  • Friend Requests: Users can send and accept friend requests.
  • Real-time Updates: Real-time updates for new posts and notifications using WebSockets.

Technologies

  • Frontend:

    • React.js
    • Redux for state management
    • React Router for navigation
    • Axios for API requests
  • Backend:

    • Node.js with Express.js
    • MongoDB for the database
    • Mongoose for ODM (Object Data Modeling)
    • Passport.js for authentication
  • Real-time Updates:

    • Socket.io for WebSocket communication

Installation

  1. Clone the repository:

    git clone https://github.com/your-username/social-media-app.git
  2. Navigate to the project directory:

    cd social-media-app
  3. Install dependencies:

    npm install
  4. Set up environment variables:

    • Create a .env file in the root directory.

    • Define the following variables:

      REACT_APP_API_URL=http://localhost:5000/api
      REACT_APP_SOCKET_URL=http://localhost:5000
      SECRET_KEY=your_secret_key
      MONGODB_URI=your_mongodb_connection_string
      
  5. Run the application:

    npm run dev

Usage

  1. Open your browser and navigate to http://localhost:3000 to access the frontend.
  2. Start exploring and using the social media app.

API Endpoints

  • GET /api/posts: Get all posts.
  • GET /api/posts/:postId: Get a specific post.
  • POST /api/posts: Create a new post.
  • PUT /api/posts/:postId: Update a post.
  • DELETE /api/posts/:postId: Delete a post.

Note: The above endpoints are just examples. You may have additional endpoints based on your app's functionality.

Contributing

Contributions are welcome! If you find any issues or have suggestions, feel free to open an issue or create a pull request.

License

This project is licensed under the MIT License.

social-media's People

Contributors

dsrathore1 avatar

Stargazers

 avatar

Watchers

 avatar

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.