An open API service indexing awesome lists of open source software.

https://github.com/ravindraogg/codecrib

Real-time private room based code collaboration platform with file sharing and live synchronization.
https://github.com/ravindraogg/codecrib

code-sharing coding-platform expressjs mongodb nodejs private-rooms reactjs real-time-collaboration socket-io typescript

Last synced: 3 months ago
JSON representation

Real-time private room based code collaboration platform with file sharing and live synchronization.

Awesome Lists containing this project

README

          


CodeCrib Logo

# โœจ CodeCrib

**CodeCrib** is a real-time collaborative coding platform that bridges the gap between theoretical learning and practical coding. Designed for interview preparation, it offers structured problem sets, secure code sharing, and a smooth UI โ€” all in one place!

---

## ๐Ÿ“œ Table of Contents
- [About](#-about)
- [Problem Statement](#-problem-statement)
- [Objectives](#-objectives)
- [Tech Stack](#-tech-stack)
- [System Architecture](#-system-architecture)
- [Modules](#-modules)
- [Setup Instructions](#-setup-instructions)
- [Folder Structure](#-folder-structure)
- [Results & Performance](#-results--performance)
- [Applications](#-applications)
- [Future Enhancements](#-future-enhancements)
- [License](#-license)

---

## ๐Ÿ”ฅ About

**CodeCrib** is a full-stack platform that allows:
- Categorized coding problem practice with progress tracking.
- Real-time collaborative editing for interviews or pair programming.
- Upload of code files for sharing and solving with peers.
- Seamless integration of UI/UX for improved learning flow.

Ideal for:
- Interview prep
- Coding bootcamps
- Live peer reviews
- DSA practice

---

## โ— Problem Statement

Aspiring developers often lack access to a beginner-friendly and structured platform that supports real-time practice, progress tracking, and interview-level coding problems โ€” all in one place. Existing platforms are either paywalled, cluttered, or lack collaboration.

---

## ๐ŸŽฏ Objectives

- โœ… Structured coding problem sets categorized by difficulty.
- โœ… Real-time code collaboration using WebSockets.
- โœ… Secure authentication & user sessions.
- โœ… Admin-level problem management and uploads.
- โœ… Intuitive UI for smooth coding workflows.
- โœ… Beginner-focused, free-to-use experience.

---

## ๐Ÿ› ๏ธ Tech Stack

| Frontend | Backend | Realtime | Storage / Database |
|------------------|----------------------|--------------------|--------------------------|
| React.js + TypeScript | Node.js + Express.js | Socket.IO | MongoDB (NoSQL) |
| Vite + CSS | Multer (file uploads) | WebSocket Protocol | Local Disk for files |
| CodeMirror / Monaco | CORS Middleware | Room Events | Memory & DB Storage |

---

## ๐Ÿง  System Architecture

- **Frontend**: Built with React + Vite + TypeScript. Handles the UI, problem display, authentication, and WebSocket sync.
- **Backend**: Node.js + Express with REST APIs for problems, users, and submissions. Handles Multer uploads and room sync.
- **Database**: MongoDB to store user data, problem sets, and submissions.
- **Real-Time Engine**: Socket.IO enables collaborative editing via WebSocket connections.
![diagram-export-5-15-2025-9_28_33-PM](https://github.com/user-attachments/assets/446d9823-c5ee-484e-aba8-b10f7fde0efc)

---

## ๐Ÿงฉ Modules

### 1. **User Interface**
- Responsive interface for problems, dashboard, login/signup.
- Dynamic rendering of problems and editors.

### 2. **Authentication**
- Secure login/signup.
- JWT or session-based auth.
- CORS-protected routes.

### 3. **Problem Management**
- Admin APIs for creating/editing problems.
- Metadata includes title, description, sample I/O, difficulty.

### 4. **Solution & Evaluation**
- Submit solutions with metadata.
- Track submission history and status.

### 5. **Collaboration**
- Live typing and sync across multiple users in a room.
- WebSocket-driven updates.

### 6. **File Upload**
- Accepts only `.js`, `.py`, `.cpp`, `.txt`, etc.
- Validates max 20MB size, rejects folders/ZIPs.

### 7. **Progress Tracking**
- Monitor attempted/solved problems.
- Display analytics, streaks, and category stats.

---

## ๐Ÿš€ Setup Instructions

1. **Clone the repository:**
```bash
git clone https://github.com/ravindraogg/codecrib.git
cd codecrib

2. **Frontend Installation:**

```bash
cd frontend
npm install
npm run dev
```

3. **Backend Installation:**

```bash
cd backend
npm install
npm run start
```

4. **Environment Variables:**
Create a `.env` in `backend/`:

```bash
PORT=5000
MONGO_URI=your_mongodb_connection_string
```

5. **Run the app locally:**
Visit `http://localhost:5173`

---

## ๐Ÿ“ Folder Structure

```
/frontend
/src
/components
/pages
index.html
vite.config.js

/backend
/file
/uploads
server.js
```

---

## ๐Ÿ“Š Results & Performance

* โšก UI loads under 1.5s due to Vite optimization.
* ๐Ÿš€ API latency: \~150ms avg response time.
* ๐Ÿ”„ Real-time sync: latency < 100ms.
* ๐Ÿ“ Upload handling & DB queries show minimal lag.

---

## ๐Ÿ’ก Applications

* ๐Ÿ‘จโ€๐ŸŽ“ Students: Learn and practice for placements.
* ๐Ÿง‘โ€๐Ÿซ Trainers: Conduct collaborative sessions.
* ๐Ÿงช Bootcamps: Teach DSA live and track progress.
* ๐Ÿ‘ฅ Peer Coding: Improve logic with real-time feedback.
* ๐Ÿงฉ Practice Arena: Sharpen DSA skills with others.

---

## ๐Ÿงญ Future Enhancements

* ๐Ÿ’ฌ Live code execution and output testing.
* ๐ŸŒ Multilingual coding support (Python, Java, etc.).
* ๐Ÿ“ˆ Analytics dashboard for user growth.
* ๐Ÿ† Leaderboards, streaks, gamification.
* ๐Ÿ“ฑ Mobile App for Android/iOS.
* ๐Ÿ“น Voice & Video Chat, session recordings.
* โ˜๏ธ Cloud-based deployment with scalability.

---
## ๐Ÿ‘จโ€๐Ÿ’ป Contributors

| Name | GitHub Profile | Image |
|---------------|--------------------------------------|--------|
| **Ravindra S** | [ravindraog](https://github.com/ravindraog) | |
| **Nitesh** | [PanatiNitesh](https://github.com/PanatiNitesh) | |
| **Masood** | _Masood_ | |
| **Vedanth** | _Vedanth_ | |

## ๐Ÿ“„ License

This project is licensed under the **MIT License**.

---

## ๐Ÿ”– Badges

![GitHub Repo stars](https://img.shields.io/github/stars/ravindraogg/codecrib?style=social)
![GitHub forks](https://img.shields.io/github/forks/ravindraogg/codecrib?style=social)
![GitHub issues](https://img.shields.io/github/issues/ravindraogg/codecrib)
![GitHub license](https://img.shields.io/github/license/ravindraogg/codecrib)

---