How forkzen/crisisboard works
Project type and purpose
• From the README and file tree, this is a full-stack, serverless web application called “CrisisBoard.”
• Purpose: let college students submit anonymous (or identified) complaints, auto-categorize them via AI, email them to the correct department, and store them in a safe database.
File structure
• Top-level files:
• .firebaserc, firebase.json → Firebase Hosting & configuration
• index.html (root) + public/ → static front-end assets (React bundle, Firebase config)
• build/ → packaged artifacts (e.g., JAR) – possibly legacy or CI output
• .idx/dev.nix, .vscode/ → development environment setups
• No explicit functions/ folder present, but README indicates Firebase Cloud Functions handle backend logic.
README for additional insights
• Backend tech: Firebase Authentication, Firestore (NoSQL DB), Cloud Functions (business logic), Gemini API (AI categorizer), SendGrid/Nodemailer (email delivery)
• Client (Web Browser)
• Firebase Hosting (serves index.html + public/app.js)
• React SPA (UI layer)
• Firebase Authentication (login gate)
• Firestore Database (complaint storage)
• Firebase Cloud Functions (serverless business logic)
• Google Gemini API (AI categorization)
• Email Service (SendGrid or SMTP via Nodemailer)
1. User → Firebase Hosting → React SPA
2. React SPA ↔ Firebase Auth (login session)
3. On complaint submit:
• React SPA → Cloud Function (invoke via HTTPS or callable)
• Cloud Function → Gemini API (get category)
• Cloud Function → Firestore (save complaint + metadata)
• Cloud Function → Email Service (send to appropriate department)
4. React SPA → Firestore (read list of past complaints)
5. React SPA → Cloud Function (delete complaint)
c. Architectural patterns & principles:
• Serverless/event-driven (Cloud Functions trigger on HTTPS calls or DB writes)
• SPA on the client, thin backend layer
• Externalization of AI logic (Gemini API)
• Secure, role-based access via Firebase Auth
d. Key technologies to annotate:
• React (browser)
• Tailwind CSS & Framer Motion (UI styling & animation)
• Firebase Hosting, Auth, Firestore, Functions
• Google Gemini API
• SendGrid/Nodemailer