A modern web application for tracking your reading progress built with React frontend, Flask backend and Azure Postgres database. Keep track of your books, reading sessions, and monitor your reading goals with detailed statistics and progress visualization.
- Add Books - Add books with title, author, total pages, and initial reading status
- Reading Status Tracking - Three status levels: "To be read", "Reading", "Read Done"
- Visual Status Indicators - Color-coded badges for quick status identification
- Progress Visualization - Beautiful progress bars showing completion percentage
- Reading Logs - Track daily reading sessions with date and pages read
- Pending Pages - Automatically calculates remaining pages for each book
- Progress Percentage - Shows completion percentage for individual books
- Reading History - View all your reading sessions for each book
- Overall Statistics - Total books in each status category
- Reading Progress - Total pages read vs pages pending across your library
- Completion Tracking - Overall progress percentage across all books
- Real-time Updates - Statistics update automatically as you log progress
- Beautiful Design - Modern gradient background with clean white cards
- Responsive Layout - Works perfectly on desktop, tablet, and mobile
- Interactive Elements - Smooth animations and hover effects
- Intuitive Interface - Easy-to-use forms and navigation
- Node.js (v14 or higher)
- Python (v3.8 or higher)
- PostgreSQL database (local or Azure)
git clone <your-repo-url>
cd myreadingtracker# Navigate to backend folder
cd backend
# Create virtual environment
python -m venv venv
# Activate virtual environment
# On Windows:
.\venv\Scripts\Activate.ps1
# On macOS/Linux:
source venv/bin/activate
# Install dependencies
pip install -r requirements.txt
# Set database URL (replace with your credentials)
$env:DATABASE_URL = 'postgresql://username:password@host:5432/database?sslmode=require'
# Initialize database tables
python init_db.py
# Start the Flask server
python app.py# Navigate to frontend folder (in a new terminal)
cd frontend
# Install dependencies
npm install
# Start the React development server
npm startNavigate to http://localhost:3000 to start using your Reading Tracker!
myreadingtracker/
βββ backend/ # Flask API server
β βββ app.py # Main Flask application
β βββ init_db.py # Database initialization script
β βββ migrate_status.py # Migration script for status feature
β βββ requirements.txt # Python dependencies
β βββ schema/ # Database schema files
β β βββ init_tables.sql # Initial table creation
β β βββ add_status_column.sql # Status column migration
β βββ venv/ # Virtual environment
βββ frontend/ # React application
β βββ public/ # Static files
β βββ src/ # React source code
β β βββ App.js # Main React component
β β βββ App.css # Styling
β β βββ index.js # React entry point
β βββ package.json # Node dependencies
β βββ node_modules/ # Node packages
βββ docker-compose.yml # Docker setup for PostgreSQL
βββ READING_PROGRESS_FEATURE.md # Feature documentation
βββ README.md # This file
GET /api/books- Get all books with progress informationPOST /api/books- Add a new bookPUT /api/books/{id}/status- Update book reading status
GET /api/logs/{book_id}- Get reading logs for a specific bookPOST /api/logs- Add a new reading log entry
GET /api/stats- Get overall reading statistics
Beautiful statistics dashboard showing your reading progress across all books.
Clean interface for managing your book collection with status tracking.
Detailed progress visualization with animated progress bars.
# Install PostgreSQL locally
# Create database and user
psql -U postgres -c "CREATE USER reader WITH PASSWORD 'password';"
psql -U postgres -c "CREATE DATABASE readingtracker OWNER reader;"
# Set environment variable
$env:DATABASE_URL = 'postgresql://reader:password@localhost:5432/readingtracker'# Create Azure PostgreSQL Flexible Server
az postgres flexible-server create \
--resource-group myResourceGroup \
--name readingtracker-server \
--location eastus \
--admin-user reader \
--admin-password YourSecurePassword
# Set environment variable
$env:DATABASE_URL = 'postgresql://reader:[email protected]:5432/readingtracker?sslmode=require'# Use the included docker-compose.yml
docker-compose up -d
# Set environment variable for local Docker
$env:DATABASE_URL = 'postgresql://reader:readerpass@localhost:5432/readingtracker'- Backend: Add new endpoints in
app.py - Frontend: Update React components in
src/App.js - Database: Add migration scripts in
schema/folder - Styling: Update CSS in
src/App.css
# Backend tests (if implemented)
cd backend
python -m pytest
# Frontend tests
cd frontend
npm test- β Added reading status tracking (To be read, Reading, Read Done)
- β Implemented pending pages calculation
- β Added progress percentage tracking
- β Enhanced statistics dashboard
- β Beautiful progress bars and visual indicators
- β Basic book management
- β Reading log tracking
- β React frontend with Flask backend
- β PostgreSQL database integration
- Fork the repository
- Create a feature branch (
git checkout -b feature/new-feature) - Commit your changes (
git commit -am 'Add new feature') - Push to the branch (
git push origin feature/new-feature) - Create a Pull Request
This project is open source and available under the MIT License.
Database Connection Error
# Check your DATABASE_URL format
echo $env:DATABASE_URL
# Verify PostgreSQL is running
# For local: Check PostgreSQL service
# For Azure: Check firewall rules and connection stringFrontend Not Loading
# Clear npm cache
npm cache clean --force
# Reinstall dependencies
rm -rf node_modules package-lock.json
npm installBackend API Errors
# Check Flask is running on port 5000
curl http://localhost:5000/api/books
# Verify virtual environment is activated
which python # Should show venv pathIf you encounter any issues or have questions:
- Check the troubleshooting section above
- Review the feature documentation in
READING_PROGRESS_FEATURE.md - Create an issue in the repository
Happy Reading! πβ¨
Built with β€οΈ using React, Flask, PostgreSQL and Github Copilot