PowerBooks
Book loan management and catalog platform with authentication, advanced search, and Firebase persistence.

Project Overview
Book lending and discovery. Problem: syncing loan status and availability in real time. Solution: Firebase + NextAuth + Clean Architecture. Stack: Next.js, React, Firebase, Firestore, 2FA with TOTP. Result: search with the Google Books API, wishlist with notifications, Lighthouse >90.
Core Modules
Book Catalog & Advanced Search
Displays books from public APIs (Google Books / Open Library). Implements search by title, author, and keywords, with filters by category and sorting by popularity or date. Includes pagination and skeleton loading to improve perceived performance.
Authentication & Profile Management
Traditional login/registration (email/password) and Google sign-in using NextAuth.js + Firebase. Protected routes via middleware. User profile with sections: 'My Library' (borrowed, reading, completed books) and personal data.
Loan System & Due Dates
Allows borrowing books for a defined period (e.g. 14 days). Records loan and due dates. History stored in Firestore. Shows upcoming due-date notifications and supports automatic renewal if the book is available.
Wishlist & Reading Tracker
Users can add books to a wishlist and mark reading progress (Reading, Completed, Abandoned). Integrated with the notification system to alert users when a desired book becomes available for loan.
Security & Validation
Input sanitization with DOMPurify, form validation with Zod, XSS and CSRF protection. Routes protected by middleware verifying the active session. Firestore security rules at the document level. Optional 2FA with TOTP.
Real-Time Notifications & Emails
Push notification system (Firebase Cloud Messaging) for due-date alerts, wishlist availability, and loan confirmations. Transactional emails sent via Resend (welcome, loan confirmation, due-date reminder).
Performance Optimization & Accessibility
Images optimized with next/image and lazy loading. Lighthouse score above 90 for performance and accessibility. Keyboard navigation, ARIA roles, color contrast, and semantic HTML tags. SSR/SSG for the static catalog and CSR for dynamic sections.
Technologies Implemented
frontend
backend
ai And Storage
tools
System Gallery





