Thank you for your interest in contributing to Coding for MBA! We welcome improvements to the curriculum, bug fixes, documentation updates, and new features.
Please take a moment to review this guide to ensure a smooth contribution process.
- Node.js: Version 18 or higher.
- npm: Comes with Node.js.
- Git: For version control.
-
Clone the repository:
git clone https://github.com/saint2706/Coding-For-MBA.git cd Coding-For-MBA -
Install dependencies:
npm install
-
Start the development server:
npm run dev
The app will be available at
http://localhost:5173/(or another port if 5173 is busy).
src/: Source code (React components, utilities, pages).components/: Reusable UI components.utils/: Core logic (content loading, Pyodide integration, state).stores/: Zustand state stores.
content/lessons/: Markdown content for the 140-day curriculum.docs/: Documentation files (Roadmap, Architecture).scripts/: Build and validation scripts.tests/: E2E tests (Playwright).
-
Create a new branch for your feature or fix:
git checkout -b feature/my-new-feature # or git checkout -b fix/bug-description -
Make your changes. Ensure you follow the project code style.
-
Validate your changes:
- Run type checks:
npm run typecheck - Format code:
npm run format - Verify content integrity:
npm run validate-content
- Run type checks:
-
Commit your changes:
- Use clear, descriptive commit messages.
- Example:
feat: Add new exercise widget for SQLorfix: Correct typo in Day 12 lesson.
We use Vitest for unit testing and Playwright for end-to-end testing.
-
Run unit tests:
npm test -
Run unit tests in watch mode:
npm run test:watch
-
Run E2E tests:
npm run test:e2e
Note: E2E tests require the dev server to be running or built.
- Prettier: We enforce code formatting with Prettier. Run
npm run formatbefore committing. - TypeScript: We use strict TypeScript configuration. Ensure
npm run typecheckpasses.
To ensure generated documentation and intellisense features work properly, all exported functions and React components must have a JSDoc block immediately preceding the export keyword.
- Use standard
/** ... */syntax. - Include a descriptive summary of what the function/component does.
- Document all parameters using
@param. - Document the return value using
@returns. - Avoid placing imports between the JSDoc block and the
exportstatement.
Example:
/**
* Calculates the total price including tax.
*
* @param {number} subtotal - The subtotal amount.
* @param {number} taxRate - The tax rate (e.g., 0.2 for 20%).
* @returns {number} The total price.
*/
export function calculateTotal(subtotal: number, taxRate: number): number {
return subtotal * (1 + taxRate);
}- Push your branch to GitHub.
- Open a Pull Request (PR) against the
mainbranch. - Describe your changes clearly in the PR description.
- Ensure all CI checks pass (Lint, Typecheck, Tests).
- A maintainer will review your PR and may request changes.
- User Documentation: Located in
README.md. - Architecture: See
docs/ARCHITECTURE.md. - Roadmap: See
docs/todo.md.
Thank you for contributing!