Skip to content

abhigp27/fit-connect

Repository files navigation

GymConnect

Setup Instructions

  1. Clone the repository

  2. Install dependencies: npm install

  3. Set up your Firebase project and add the configuration to lib/firebase.ts

  4. Create the following indexes in Firestore:

    • Collection: bookings Fields: trainerId (Ascending), date (Descending)
    • Collection: bookings Fields: clientId (Ascending), date (Descending)
    • Collection: users Fields: role (Ascending), services (Array contains)

    To create these indexes: a. Go to your Firebase Console (https://console.firebase.google.com/) b. Select your project c. In the left sidebar, click on "Firestore Database" d. Go to the "Indexes" tab e. Click on "Add index" f. Fill in the details for each index as specified above g. Click "Create index"

    Note: It may take a few minutes for the indexes to be created and become active.

  5. Run the development server: npm run dev

Features

  • User authentication (trainers and clients)
  • Trainer profiles
  • Booking system
  • Dashboard for trainers and clients

Technologies Used

  • Next.js
  • React
  • Firebase (Authentication, Firestore)
  • Tailwind CSS
  • shadcn/ui components

Troubleshooting

If you encounter any "failed-precondition" errors, please ensure that you have created all the necessary Firestore indexes as described in the setup instructions. It may take a few minutes for the indexes to become active after creation.

About

Created with StackBlitz ⚡️

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published