Skip to content

Andre-Tita/IWGD

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Community Runners 🏃‍♂️

A full-stack web application that connects runners and helps them organize group running events. Users can create runs, join existing ones, share experiences through posts and comments, and build a community around running activities.

🚀 Features

User Management

  • User registration and authentication
  • Profile management with profile pictures
  • JWT-based secure authentication

Run Organization

  • Create running events with details (title, description, date, location, distance)
  • Join/leave runs as a participant
  • View upcoming runs and personal run history
  • End runs when completed

Social Features

  • Post updates and photos about runs
  • Comment on posts
  • Run-specific feeds for community interaction

🛠️ Tech Stack

Backend

  • Django 5.2 - Web framework
  • Django REST Framework - API development
  • SQLite - Database
  • JWT Authentication - Secure token-based auth
  • CORS - Cross-origin resource sharing

Frontend

  • React 18 - UI library
  • React Router - Client-side routing
  • Axios - HTTP client
  • Bootstrap 5 - CSS framework

📋 Prerequisites

  • Python 3.8+
  • Node.js 14+
  • npm or yarn

🔧 Installation & Setup

Backend Setup

  1. Navigate to backend directory:

    cd backend
  2. Create virtual environment:

    python -m venv venv
    source venv/bin/activate  # On Windows: venv\Scripts\activate
  3. Install dependencies:

    pip install django djangorestframework djangorestframework-simplejwt django-cors-headers pillow
  4. Run migrations:

    python manage.py makemigrations
    python manage.py migrate
  5. Create superuser (optional):

    python manage.py createsuperuser
  6. Start the Django server:

    python manage.py runserver

The backend will be running at http://localhost:8000

Frontend Setup

  1. Navigate to frontend directory:

    cd frontend
  2. Install dependencies:

    npm install
  3. Start the React development server:

    npm start

The frontend will be running at http://localhost:3000

📖 Usage

  1. Register a new account or login with existing credentials
  2. Create runs by specifying title, description, date, location, and distance
  3. Browse available runs on the homepage and join ones that interest you
  4. View your runs in the "My Runs" section
  5. Post updates about runs with photos and text
  6. Comment on posts to engage with the community
  7. End runs when they're completed (creator only)
  8. View run history to see past completed runs

🔌 API Endpoints

Authentication

  • POST /api/register/ - User registration
  • POST /api/login/ - User login
  • POST /api/logout/ - User logout
  • GET /api/profile/ - Get user profile
  • PATCH /api/profile/ - Update user profile

Runs

  • GET /api/runs/ - List all runs
  • POST /api/runs/ - Create new run
  • POST /api/runs/{id}/join-leave/ - Join or leave a run
  • POST /api/runs/{id}/end/ - End a run (creator only)
  • GET /api/my-runs/ - Get runs created by user
  • GET /api/run-history/ - Get completed runs for user

Social Features

  • GET /api/runs/{run_id}/feed/ - Get posts for a run
  • POST /api/runs/{run_id}/feed/ - Create post for a run
  • POST /api/posts/{post_id}/comments/ - Add comment to post

🗂️ Project Structure

IWGD/
├── backend/
│   ├── community_app/
│   │   ├── models.py          # Database models (User, Run, Post, Comment)
│   │   ├── views.py           # API endpoints
│   │   ├── serializers.py     # Data serialization
│   │   ├── urls.py            # URL routing
│   │   └── ...
│   ├── community_project/
│   │   ├── settings.py        # Django settings
│   │   ├── urls.py            # Main URL configuration
│   │   └── ...
│   ├── manage.py              # Django management script
│   └── db.sqlite3             # SQLite database
├── frontend/
│   ├── src/
│   │   ├── components/        # Reusable React components
│   │   ├── pages/             # Page components
│   │   ├── services/          # API service functions
│   │   ├── App.js             # Main app component
│   │   └── index.js           # App entry point
│   ├── public/                # Static assets
│   └── package.json           # Dependencies and scripts
└── README.md

🤝 Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

📝 License

This project is licensed under the MIT License - see the LICENSE file for details.

📧 Contact

If you have any questions or suggestions, feel free to reach out!

🔄 Future Enhancements

  • Real-time notifications for run updates
  • GPS tracking during runs
  • Run statistics and analytics
  • Social media integration
  • Mobile app version
  • Group messaging for runs
  • Run difficulty levels and categories

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages