Skip to content

Repository files navigation

MathTutor

Structured math tutoring from basic numbers toward calculus. React + Vite + TypeScript SPA with Path mode, Topics mode, and optional free-tier auth for progress sync.

Quick start

npm install
npm run dev

Open the local URL Vite prints (usually http://localhost:5173).

The app works with no backend: guest progress is stored in localStorage.

Optional: free cloud sync (Supabase)

  1. Create a free project at supabase.com.
  2. In the SQL editor, run supabase/schema.sql.
  3. Copy .env.example to .env and set:
VITE_SUPABASE_URL=https://YOUR_PROJECT.supabase.co
VITE_SUPABASE_ANON_KEY=YOUR_ANON_KEY
  1. Restart npm run dev.

Sign-in is only for saving progress and attempt history across devices.

Scripts

Command Description
npm run dev Local development server
npm run build Typecheck + production build to dist/
npm run preview Preview the production build
npm run lint ESLint

Deploy on Cloudflare Pages ($0)

  1. Push this repo to GitHub (or upload the project).
  2. In Cloudflare Pages: Create project → connect the repo.
  3. Build settings:
    • Framework preset: Vite
    • Build command: npm run build
    • Build output directory: dist
  4. Add the same VITE_SUPABASE_* variables in Pages → Settings → Environment variables (if using Supabase).
  5. Deploy. public/_redirects enables React Router deep links.

You can also deploy a local build with Wrangler:

npm run build
npx wrangler pages deploy dist --project-name=mathtutor

Curriculum

All tracks are available end-to-end at MVP depth:

  1. Numbers
  2. Arithmetic
  3. Pre-Algebra
  4. Algebra
  5. Geometry
  6. Trigonometry
  7. Precalculus
  8. Calculus

Content lives under src/content/. Each lesson has explanation, worked examples, and practice.

Design

UI follows docs/DESIGN.md.

About

Math tutoring from numbers through calculus — React + Vite + Supabase

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages