A full-stack book review platform that allows users to browse, review, and manage books. The application provides features for book enthusiasts, including user authentication, book reviews, favorites, and admin management.
- React.js
- React Router
- Axios for API calls
- Tailwind CSS for styling
- Node.js
- Express.js
- MongoDB (Mongoose)
- JSON Web Token (JWT) for authentication
- bcryptjs for password hashing
- mongoose: ODM for MongoDB
- jsonwebtoken: Authentication
- bcryptjs: Password encryption
- cors: Cross-origin resource sharing
- dotenv: Environment variable management
- User Authentication (Signup/Login)
- Book Browsing
- Book Details and Reviews
- Add Books to Favorites
- Write and Manage Reviews
- Admin Book Management
- Search and Filter Books
git clone https://github.com/pavannitheesh/Book.git
cd Book# Navigate to backend directory
cd backend
# Install dependencies
npm install
# Create .env file with the following variables
touch .envMONGODB_URI=your_mongodb_connection_string
JWT_SECRET=your_jwt_secret_key
PORT=5000
# Navigate to frontend directory
cd frontend
# Install dependencies
npm install# In backend directory
npm start
# Or with nodemon for development
npm run dev# In frontend directory
npm startPOST /api/users/signup: User registrationPOST /api/users/login: User login
GET /api/books: List booksGET /api/books/:id: Get book detailsPOST /api/books: Add new book (Admin)PUT /api/books/:id: Update book (Admin)DELETE /api/books/:id: Delete book (Admin)
GET /api/books/:id/reviews: Get book reviewsPOST /api/books/:id/reviews: Add reviewDELETE /api/reviews/:id: Delete review
GET /api/user/favorites: List favorite booksPOST /api/user/favorites: Add book to favoritesDELETE /api/user/favorites/:id: Remove from favorites
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
- Set up MongoDB database
- Implement backend models and routes
- Create authentication middleware
- Develop frontend components
- Integrate frontend with backend APIs
- Add error handling and validation
- Test thoroughly
- Deploy
book-review-platform/
│
├── frontend/
│ ├── src/
│ │ ├── components/
│ │ │ ├── BookList.js
│ │ │ ├── BookDetail.js
│ │ │ ├── UserProfile.js
│ │ │ ├── AdminAddBook.js
│ │ │ └── AdminEditBook.js
│ │ ├── App.js
│ │ └── index.js
│
├── backend/
│ ├── models/
│ │ ├── Book.js
│ │ ├── User.js
│ │ └── Review.js
│ ├── routes/
│ │ ├── bookRoutes.js
│ │ ├── userRoutes.js
│ │ └── reviewRoutes.js
│ ├── controllers/
│ │ ├── bookController.js
│ │ ├── userController.js
│ │ └── reviewController.js
│ └── server.js
│
├── .env
├── package.json
└── README.md