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

Skip to content

telasjareynolds/bookvault

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

62 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ“š Book Management App

A full stack application that allows users to manage their personal book collection. Built with React, Vite, TypeScript, Express, and MongoDB, the app enables users to securely add, edit, delete, and view books in their library with authentication. Each user will get a copy of 100 books to browse upon registration and configure or remove if desired.


✨ Features

  • User authentication (via provided backend codebase)
  • Add, edit, and delete books
  • Remove and add books to collection
  • View a list of all books added to user's collection
  • Responsive, modern UI built with React + Vite + TypeScript
  • API built with Express and TypeScript
  • MongoDB for persistent data storage

πŸ›  Tech Stack

  • Frontend: React, Vite, TypeScript
  • Backend: Node.js, Express, TypeScript
  • Database: MongoDB
  • Authentication: Pre-built backend auth system
  • Tooling: ts-node, nodemon, dotenv, mongoose

πŸ“ Project Structure

bookvault/ β”œβ”€β”€ backend/ # Express API and auth integration β”‚ β”œβ”€β”€ src/ β”‚ | β”œβ”€β”€ package.json β”‚ └── tsconfig.json β”œβ”€β”€ frontend/ # React + Vite frontend β”‚ β”œβ”€β”€ src/ β”‚ β”œβ”€β”€ package.json β”‚ └── vite.config.ts └── README.md # You're here!


πŸš€ Getting Started

Prerequisites

Make sure the following are installed on your machine:

  • Node.js (v16+)
  • npm
  • MongoDB (local or remote instance)
  • Git

1. Clone the Repository

git clone: https://github.com/tealsjareynolds/bookvaule.git cd book-management-app 2. Install Dependencies Backend- cd backend npm install

Frontend- cd ../frontend npm install

  1. Environment Variables This app includes a pre-populated database of 100 books. You have 2 options on how you'd like to access it.

Option 1: ⚠️ This connection is read-only. You’ll be able to view the 100 books, but user registration and book creation will not work unless you connect your own MongoDB. If you want to run the app without setting up your own database, you can use our hosted read-only MongoDB Atlas database: In the backend/ folder, create a .env file with the following content: PORT=3001 MONGO_URI=mongodb+srv://readonlyUser:[email protected]/bookvault?retryWrites=true&w=majority JWT_SECRET=your_jwt_secret

Replace your_jwt_secret with a secure secret key for JWT.

-- OR --

Option 2: Use this link to download the default JSON books that are set up to appear correctly throughout this project. Import them into mongodb and make sure the database is connected: https://github.com/telasjareynolds/book-file/blob/main/bookvault.books.json In the backend/ folder, create a .env file with the following content: PORT=3001 MONGO_URI=mongodb://localhost:27017/bookvault JWT_SECRET=your_jwt_secret

-- For reference, this file originally came from "https://github.com/benoitvallon/100-best-books/blob/master/books.json" but I've converted the value of id into strings for the project.

  1. Run the Application

Start the backend server- cd backend npm run dev

Start the frontend- cd ../frontend npm run dev

Frontend: http://localhost:3000

Backend: http://localhost:8000

πŸ” Authentication This project uses a provided backend authentication system. Once logged in:

  • Store the JWT token in localStorage or sessionStorage

  • Send the token in requests to protected routes using the Authorization header:

Authorization: Bearer <your_token>

βœ… Functionality Checklist

  • User can register and log in
  • User can add a new book
  • User can edit a book’s details
  • User can delete a book
  • User can view all saved books
  • Proper backend authentication integration
  • Responsive and accessible UI

πŸ“¬ Contact Built with ❀️ by Telasja Reynolds GitHub: https://github.com/telasjareynolds Email: [email protected]

About

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published