Skip to main content

Welcome Contributors

Thank you for your interest in contributing to SkillRise! This guide will help you get started with the development workflow, coding standards, and submission process.
SkillRise is an open-source project built for students and educators. We welcome contributions of all kinds - bug fixes, features, documentation, and more.

Getting Started

Prerequisites

Before you begin, ensure you have the following installed:

Node.js

Version 20 or higher required for both client and server

MongoDB

Local instance or MongoDB Atlas connection

Git

For version control and collaboration

Docker

Optional, for containerized development

Required Accounts

You’ll need accounts for the following services:
  • Clerk - Authentication and user management
  • Stripe - Payment processing
  • Cloudinary - Media storage and CDN
  • Groq - AI-powered features
All services offer free tiers suitable for development. Use test/sandbox keys for local development.

Development Setup

1. Fork and Clone

Start by forking the repository and cloning your fork:

2. Install Dependencies

Install packages for both client and server:

3. Configure Environment Variables

Create .env files with your credentials:
Never commit .env files or expose API keys in your code. These files are already in .gitignore.

4. Seed the Database (Optional)

Populate your local database with demo data:
This creates:
  • 5 demo educators and 5 demo students
  • 5 sample courses with chapters and lectures
  • Community groups, posts, and replies
  • Quizzes and sample enrollment data

5. Run the Development Servers

Start both frontend and backend in separate terminals:
The client dev server proxies API requests to http://localhost:3000 as configured in VITE_BACKEND_URL.

6. Set Up Webhooks (Optional)

For testing authentication and payments locally, forward webhooks using ngrok:
Then configure webhook URLs in your service dashboards:

Development Workflow

Branch Strategy

SkillRise follows a Git Flow-inspired branching model:
1

Create a Feature Branch

Always branch from dev, never from main:
2

Make Your Changes

Write code, add tests, update documentation as needed.
3

Commit Your Work

Use clear, descriptive commit messages:
4

Push to Your Fork

5

Open a Pull Request

Create a PR from your fork to the dev branch of the main repository.

Commit Message Convention

Use clear, imperative commit messages:

Code Standards

Linting and Formatting

SkillRise uses ESLint for code quality and Prettier for consistent formatting.
All PRs must pass ESLint and Prettier checks. The CI pipeline will automatically verify this.

JavaScript/JSX Style Guide

Component Structure

API Controllers

File Naming Conventions

  • Components: PascalCase with .jsx extension
    • CourseCard.jsx
    • UserProfile.jsx
  • Hooks: camelCase with use prefix
    • useTimeTracker.js
    • useInView.js
  • Utils: camelCase
    • formatDate.js
    • apiClient.js

Pull Request Process

Before Submitting

PR Template

When creating a pull request, include:

CI Checks

All pull requests trigger automated CI checks via GitHub Actions:
1

Client Build Job

  • Install dependencies (npm ci)
  • Run ESLint (npm run lint)
  • Check Prettier formatting (npm run format:check)
  • Build the app (npm run build)
2

Server Lint Job

  • Install dependencies (npm ci)
  • Run ESLint (npm run lint)
  • Check Prettier formatting (npm run format:check)
PRs cannot be merged if CI checks fail. Fix all issues before requesting review.

Review Process

  1. Automated Checks: CI pipeline must pass
  2. Code Review: At least one maintainer approval required
  3. Testing: Reviewers may test changes locally
  4. Merge: Once approved, maintainers will merge to dev

Development Commands Reference

Client Commands

Server Commands

Docker Commands

Common Development Tasks

Adding a New API Route

1

Create Controller Function

Add logic in appropriate controller file:
2

Define Route

Add route in corresponding routes file:
3

Test Endpoint

Use Postman or curl to test:

Adding a New React Component

1

Create Component File

2

Import and Use

Adding Environment Variables

1

Update .env Files

Add the variable to appropriate .env file(s)
2

Document in README

Update the environment variables section in documentation
3

Add to CI/CD

If needed for builds, add to GitHub Secrets and workflow files

Troubleshooting

If you see “Port 3000 already in use” or “Port 5173 already in use”:
Ensure MongoDB is running:
Reinstall dependencies:
Verify:
  • Publishable key matches in both .env files
  • Webhook secret is correct
  • ngrok URL is configured in Clerk dashboard (for local webhooks)

Getting Help

GitHub Issues

Report bugs or request features

Discussions

Ask questions and share ideas

Documentation

Read through our full documentation

Code of Conduct

Be respectful and collaborative
Remember: Good code is code that others can understand. Write clear, maintainable code and document complex logic.

Project Structure

Understand the codebase organization

Testing Guide

Learn about testing approaches