Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LOWKEY 💬

Lowkey is a real-time chat application built using Node.js and WebSockets. Developed as part of my 2019 final year project, it allows users to engage in live conversations via a responsive and lightweight interface. The application requires a database service running on a separate port for proper data handling.

Features

  • Real-time messaging with WebSockets
  • Secure password hashing
  • Event-driven communication
  • Simple and easy-to-use interface

Prerequisites

Ensure you have the following installed:

  • Node.js – Core framework for backend development
  • Nodemon – Automatically restarts the server on file changes
  • A running MySQL database instance

Node.js Check:

Ensure Node.js is installed by running:

node -v

Installation

Follow these steps to set up the project locally:

  1. Clone the Repository:

    git clone <repository-link>
    cd lowkey
  2. Install Dependencies:

    npm install
  3. Set Environment Variables:

    Copy the .env.example file and rename it to .env:

    cp .env.example .env

    Update the .env file with your configuration. Here’s an example configuration:

    # Database Configuration
    MYSQL_HOST = 'localhost'
    MYSQL_USER = 'root'
    MYSQL_PASSWORD = 'password'
    MYSQL_DATABASE = 'lowkey-db'
    MYSQL_CONNECTION_LIMIT = 100
    MYSQL_MULTISTATEMENTS = true
    
    # Authentication Keys
    AUTH_SALT = 10
    AUTH_SECRET_KEY = 'abcdefghijklmnopqrstuvwxyz'
    
    # Mailer Authentication
    MAILER_SERVICE = 'gmail'
    MAILER_AUTH_USER = '[email protected]'
    MAILER_AUTH_PASS = 'password'

    Ensure the MySQL database is running and accessible with the credentials you provide.

  4. Start the Database:

    Make sure your MySQL database is running with the necessary configurations as set in your .env file.

  5. Start the Application:

    Use the following command to start the application:

    npm run dev

    This will launch the application on http://localhost:3000 using Nodemon, which automatically restarts the server when file changes are detected.

Key Technologies

Usage

Once the application is running, visit http://localhost:3000 to start interacting with the chat interface. You can open multiple browser windows or devices to simulate multiple users.

Troubleshooting

  • Database connection issues: Ensure MySQL is running with the correct host and credentials as specified in the .env file.
  • Server errors: Check logs for detailed error messages and review your environment variable setup.

Future Enhancements

  • Improve the front-end for a more user-friendly experience
  • Implement OAuth or JWT-based authentication for more secure user sessions

About

School Final Year Project — Lowkey a realtime chat messaging web app — July 2019 — Grade 20/20

Resources

Stars

1 star

Watchers

1 watching

Forks

Used by

Contributors

Languages