First off, thank you for considering contributing to Avelo! It's people like you that make Avelo such a great tool. We welcome contributions from the community and are grateful for any time you can dedicate.
- Code of Conduct
- Getting Started
- Development Setup
- Making Changes
- Style Guidelines
- Commit Guidelines
- Pull Request Process
- Community
This project and everyone participating in it is governed by our Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to hello@avelo.com.
-
Fork the Repository
- Click the 'Fork' button at the top right of this repository
- Clone your fork locally:
git clone https://github.com/YOUR-USERNAME/avelo.git
-
Create a Branch
- Create a branch for your feature:
git checkout -b feature/your-feature-name
- Use descriptive branch names (e.g.,
feature/add-payment-gateway
,fix/navbar-responsive
)
- Create a branch for your feature:
-
Install Dependencies
cd avelo npm install
- Node.js (v18 or higher)
- npm (v8 or higher)
- Git
-
Copy the example environment file:
cp .env.example .env
-
Start the development server:
npm run dev
-
File Structure
- Place new components in
src/components
- Create a new directory for complex components
- Include tests in
__tests__
directory
- Place new components in
-
Naming Conventions
- Use PascalCase for component files (e.g.,
ProductCard.tsx
) - Use camelCase for utility files
- Use kebab-case for CSS files
- Use PascalCase for component files (e.g.,
-
TypeScript
- Always define proper interfaces for props
- Export interfaces when they might be reused
- Use proper type annotations
import React from 'react';
import styles from './ComponentName.module.css';
interface ComponentNameProps {
prop1: string;
prop2?: number;
}
const ComponentName: React.FC<ComponentNameProps> = ({ prop1, prop2 = 0 }) => {
return (
<div className={styles.container}>
{/* Component content */}
</div>
);
};
export default ComponentName;
-
Follow the existing color palette:
colors: { primary: { /* Rose tones */ }, secondary: { /* Muted blues */ }, accent: { /* Soft pinks */ }, cream: '#FDF8F5', sand: '#E5DCD7', stone: '#A69F99', charcoal: '#2C2825' }
-
Use Tailwind's utility classes consistently
-
Maintain responsive design principles
-
Follow mobile-first approach
- Use functional components with hooks
- Implement proper error handling
- Write meaningful comments for complex logic
- Use TypeScript's strict mode
-
Commit Message Format
type(scope): subject body footer
-
Types
- feat: New feature
- fix: Bug fix
- docs: Documentation changes
- style: Code style changes (formatting, etc.)
- refactor: Code refactoring
- test: Adding tests
- chore: Maintenance tasks
-
Example
feat(product): add size selector component - Implement size selection functionality - Add size availability check - Include size guide modal Closes #123
-
Before Submitting
- Update documentation if needed
- Add tests for new features
- Ensure all tests pass:
npm run test
- Run linting:
npm run lint
- Update the README.md if needed
-
PR Description Template
## Description Brief description of changes ## Type of Change - [ ] Bug fix - [ ] New feature - [ ] Breaking change - [ ] Documentation update ## How Has This Been Tested? Describe testing process ## Checklist - [ ] My code follows style guidelines - [ ] I have commented my code where needed - [ ] I have updated documentation - [ ] My changes generate no warnings - [ ] I have added tests - [ ] All tests pass
Thank you for contributing to Avelo! 🌟