Skip to content

About

Weight Tracker web application

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

23 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

Weight Challenge – Invite-only Web App

An invite-only weight tracking web application with weekly leaderboards and email reminders.

This project is designed to be:

  • Free-tier friendly
  • Simple to operate
  • Easy to extend
  • Built with modern, cloud-native tools

✨ Features

  • 🔐 Invite-only access (Google OAuth + whitelist)
  • 📊 Weekly weight check-ins
  • 🏆 Weekly leaderboard (weekly weight delta)
  • 📧 Weekly reminder & leaderboard emails
  • 📱 PWA-ready (add to home screen on mobile)
  • ☁️ Static frontend + serverless backend (BaaS)

🧱 Tech Stack

Frontend

  • React
  • Vite
  • TypeScript
  • Static SPA

Hosting

  • Cloudflare Pages

Backend / BaaS

  • Supabase
    • Google OAuth
    • Postgres (relational database)
    • Row Level Security (RLS)

Automation

  • GitHub Actions (cron)
  • Python (scheduled jobs)

🗂 Repository Structure

/
├─ apps/
│  └─ web/              # React + Vite frontend
├─ supabase/            # SQL schema, RLS, views
├─ jobs/                # Python cron jobs
├─ .github/workflows/   # GitHub Actions schedules
├─ docs/          # AI agent guidance
├─ AGENTS.md
└─ README.md

🔐 Access Model (Invite-only)

  1. User logs in with Google
  2. User email is checked against a whitelist
  3. If whitelisted → access granted
  4. If not → access denied

Whitelist enforcement is implemented at the database level using Row Level Security (RLS).


🚀 Deployment

Frontend

  • Hosted on Cloudflare Pages
  • Build command: npm run build
  • Output directory: apps/web/dist

Backend

  • Supabase manages authentication and database access
  • No custom backend server required for MVP

⏰ Scheduled Jobs

  • Weekly reminder email (users missing check-in)
  • Weekly leaderboard email
  • Optional keepalive job (prevent Supabase inactivity pause)

All jobs are executed via GitHub Actions using Python scripts.


🧪 Local Development

Frontend

cd apps/web
npm install
npm run dev

Environment Variables

Create apps/web/.env.local:

VITE_SUPABASE_URL=your_project_url
VITE_SUPABASE_ANON_KEY=your_public_anon_key

✅ MVP Definition of Done

The MVP is considered complete when:

  • Users can log in using Google
  • Only whitelisted users can access the application
  • Weekly weight check-ins are persisted
  • Leaderboard renders correct weekly rankings
  • Weekly reminder and leaderboard emails are sent
  • App can be added to the home screen as a PWA

About

Weight Tracker web application

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages