Library Management System (LMS)
This is a simple Library Management System (LMS) built using Node.js, Express, and EJS for the front-end. The system supports user authentication, book management (add/remove), and a member dashboard for borrowing/returning books.
Features
- Admin Panel: Manage books, view user details, and remove users if no books are borrowed.
- Member Panel: Borrow and return books, view borrowed book details.
- Book Inventory: Add and remove books from the system (admin-only).
- User Management: Admin can view user details and remove users (if they have not borrowed any books).
Table of Contents
- Prerequisites
- Installation
- Run Locally
- Usage
- Folder Structure
- License
Prerequisites
Before you begin, ensure you have the following installed:
- Node.js: You need Node.js to run the backend server. Download and install it from here.
- npm: Node package manager (npm) is included with Node.js, but make sure it's updated by running npm install -g npm.
Installation
-
Clone the repository:
-
Open a terminal (or command prompt) and run the following command to clone this repository:
git clone https://github.com/yourusername/LMS.git
-
Navigate to the project directory: After cloning the repository, go into the project folder: cd LMS
Install dependencies:
The next step is to install the required dependencies for the project. Run the following command in the terminal: npm install
This will install all the necessary packages listed in package.json.
Run Locally
Once all dependencies are installed, you can start the server locally.
Run the following command to start the application: npm run dev
Alternatively, if you are using the standard Node.js command (without nodemon), run: node server.js
Open a browser and go to http://localhost:3000. You should be able to see the login or signup page.
Usage
- Login & Signup
- Login: Users can log in using their credentials (username and password).