2.5 KiB
2.5 KiB
Contributing to MyTube
First off, thanks for taking the time to contribute! 🎉
The following is a set of guidelines for contributing to MyTube. These are mostly guidelines, not rules. Use your best judgment, and feel free to propose changes to this document in a pull request.
Getting Started
Prerequisites
Before you begin, ensure you have the following installed:
Installation
- Fork the repository on GitHub.
- Clone your fork locally:
git clone https://github.com/your-username/mytube.git cd mytube - Install dependencies for both frontend and backend:
Alternatively, you can install them manually:
npm run install:allnpm install cd frontend && npm install cd ../backend && npm install
Running Locally
To start the development environment (both frontend and backend):
npm run dev
- Frontend: http://localhost:5556
- Backend API: http://localhost:5551
Project Structure
frontend/: React application (Vite + TypeScript).backend/: Express.js API (TypeScript).docker-compose.yml: Docker configuration for running the full stack.
Development Workflow
- Create a Branch: Always work on a new branch for your changes.
git checkout -b feature/my-awesome-feature # or git checkout -b fix/annoying-bug - Make Changes: Implement your feature or fix.
- Commit: Write clear, descriptive commit messages.
We recommend following Conventional Commits convention.
git commit -m "feat: add new video player controls"
Code Quality
Frontend
- Run linting to ensure code style consistency:
cd frontend npm run lint
Backend
- Run tests to ensure nothing is broken:
cd backend npm run test
Pull Request Process
- Ensure your code builds and runs locally.
- Update the
README.mdif you are adding new features or changing configuration. - Push your branch to your fork on GitHub.
- Open a Pull Request against the
mainbranch of the original repository. - Provide a clear description of the problem and solution.
- Link to any related issues.
License
By contributing, you agree that your contributions will be licensed under its MIT License.