Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

ghostdog1417/student-progress-tracker

Repository files navigation

Student Progress Tracker

Student Progress Tracker is a React + Firebase app for managing student records, academic performance, taught topics, curriculum structure, and goal tracking with role-based access.

What this app includes

  • Secure login with Firebase Authentication
  • Role-based routing and permissions (superadmin, teacher)
  • Dashboard with totals and reminders
  • Student management (add, list, search/filter, lifecycle status)
  • Student report view with charts, performance history, and topics taught
  • Goal tracking per student (add/update/mark complete/delete)
  • Curriculum management (subjects, chapters, concepts)
  • Admin panel for staff, classes, school options, subjects, concepts, and audit logs
  • CSV export/import tools and JSON backup export
  • Dark mode toggle and PWA manifest support

Tech stack

  • React 19
  • Vite 7
  • React Router DOM 7
  • Firebase Auth + Cloud Firestore
  • Recharts
  • Tailwind CSS

Routes (current)

  • /login
  • /dashboard
  • /profile
  • /students
  • /students/add (editor+)
  • /students/:studentId/report
  • /performance/add (editor+)
  • /topics/add (editor+)
  • /curriculum
  • /admin (superadmin only)

Project structure

  • src/pages - Route-level pages
  • src/components - Shared UI blocks, guards, controls
  • src/context - Authentication and role context
  • src/services - Firebase/Firestore data access
  • src/router - App router and route guards
  • src/lib - Firebase initialization
  • src/utils - Reporting and CSV helpers

Prerequisites

  • Node.js LTS
  • npm
  • A Firebase project with Authentication and Firestore enabled
  • Firebase CLI (optional, for deploying rules/indexes)

Environment variables

Create a .env file in the project root:

VITE_FIREBASE_API_KEY=
VITE_FIREBASE_AUTH_DOMAIN=
VITE_FIREBASE_PROJECT_ID=
VITE_FIREBASE_STORAGE_BUCKET=
VITE_FIREBASE_MESSAGING_SENDER_ID=
VITE_FIREBASE_APP_ID=

If any values are missing, the app shows a Firebase setup error at runtime.

Getting started

npm install
npm run dev

Build and preview:

npm run build
npm run preview

Lint:

npm run lint

Firebase files in this repo

  • firebase.json
  • firestore-rules.txt
  • firestore.indexes.json

Deploy rules and indexes:

firebase deploy --only firestore:rules,firestore:indexes

or

npx --yes firebase-tools deploy --only firestore:rules,firestore:indexes

Firestore collections used

  • users
  • students
  • classes
  • school_options
  • subjects
  • concepts
  • performance
  • topics_taught
  • student_goals
  • audit_logs

Notes

  • The app expects user role data in Firestore (users collection) for access control.
  • Superadmin-only workflows are isolated under /admin.
  • Some report and reminder views depend on Firestore composite indexes defined in firestore.indexes.json.

Troubleshooting

  • Firebase is not configured / missing env vars

    • Ensure all VITE_FIREBASE_* values exist in .env.
    • Restart the dev server after updating .env.
  • Login works but app access is blocked

    • Confirm a matching document exists in users/{uid} with a valid role (teacher or superadmin).
    • Sign out and sign in again after updating role data.
  • Permission denied from Firestore

    • Deploy latest rules: firebase deploy --only firestore:rules.
    • Verify you are connected to the intended Firebase project.
  • Query requires an index

    • Deploy indexes: firebase deploy --only firestore:indexes.
    • Wait a few minutes for index build completion in Firebase Console.
  • Admin actions fail for teacher creation

    • Verify Auth provider settings in Firebase and ensure API key/project settings are correct.
    • Confirm the current account has superadmin role in Firestore.
  • Blank/partial dashboard data

    • Confirm Firestore collections exist and contain readable documents.
    • Check browser console/network for failed Firebase requests.
  • Dev server starts but page is stale

    • Clear browser cache or hard refresh (Ctrl+F5).
    • Restart with npm run dev.

Production Checklist

  • Set all required VITE_FIREBASE_* environment variables in your hosting environment.
  • Verify Firebase project selection before deploy (firebase use <project-id> if using aliases).
  • Deploy Firestore rules and indexes:
    • firebase deploy --only firestore:rules,firestore:indexes
  • Ensure at least one superadmin user profile exists in users/{uid}.
  • Confirm users/{uid} documents include valid role and optional default_page.
  • Run quality checks locally:
    • npm run lint
    • npm run build
  • Smoke test critical routes after deploy:
    • /login, /dashboard, /students, /students/:studentId/report, /admin (superadmin)
  • Verify reminders, report charts, CSV export/import, and backup export on production data.

License

No license file is currently included.

About

Student Progress Tracker built with React and Firebase for managing students, performance analytics, goals, reminders, curriculum, and role-based access.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages