A faculty past-paper archive built as a static HTML/CSS/JavaScript frontend, with Supabase Auth, Postgres, and private Storage. Vercel serves the frontend and a small function that supplies the public Supabase settings at runtime.
- Sign in with Google or email and password.
- Browse approved papers and search by title, unit, or code.
- Upload PDF, JPG, PNG, and WEBP files up to 20 MB.
- Keep new submissions private until an administrator approves them.
- Use row-level security for paper metadata and storage objects.
- Track page views with Vercel Web Analytics.
- Run the SQL in
supabase/schema.sqlin the Supabase SQL Editor. - Configure Supabase Auth providers and redirect URLs.
- Import this repository into Vercel and add
SUPABASE_URLandSUPABASE_ANON_KEYas environment variables. - Leave the Vercel Root Directory blank, use the Other preset with no build command, set the Output Directory override to
frontend, then deploy.
Follow DEPLOY_SUPABASE_VERCEL.md for the full setup and review workflow.
The static pages can be previewed through any local web server, but authentication and data features require the /api/config function. For a complete local run, set SUPABASE_URL and SUPABASE_ANON_KEY, then run npm run dev from the repository root.
Only the Supabase anon/publishable key belongs in the frontend configuration. Never put a service_role key in Vercel client-facing configuration or browser code.