Thank you for your interest in contributing to VectorMail! We're building the future of email management together.
Before creating bug reports, please check the issue tracker as you might find out that you don't need to create one. When you are creating a bug report, please include as many details as possible:
- Use a clear and descriptive title
- Describe the exact steps to reproduce the problem
- Provide specific examples
- Describe the behavior you observed and what behavior you expected
- Include screenshots if applicable
- Include your environment details (OS, browser, Node version)
Enhancement suggestions are tracked as GitHub issues. When creating an enhancement suggestion, please include:
- Use a clear and descriptive title
- Provide a detailed description of the suggested enhancement
- Explain why this enhancement would be useful
- List some examples of how it would be used
- Fork the repository and create your branch from
main - Follow the coding style of the project
- Write tests for your changes
- Ensure tests pass (
npm run test:ci) - Update documentation if you're changing functionality
- Write a good commit message
-
Fork and clone the repository
git clone https://github.com/YOUR_USERNAME/Vector-Mail.git cd Vector-Mail -
Install dependencies
npm install
-
Set up environment variables
cp .env.example .env.local # Fill in your environment variables -
Start database with Docker
docker-compose up -d postgres redis
-
Run database migrations
npm run db:push
-
Start development server
npm run dev
feature/- New featuresfix/- Bug fixesdocs/- Documentation changesrefactor/- Code refactoringtest/- Adding or updating testschore/- Maintenance tasks
Examples:
feature/email-templatesfix/search-query-bugdocs/api-endpoints
We follow the Conventional Commits specification:
<type>(<scope>): <subject>
<body>
<footer>
Types:
feat: New featurefix: Bug fixdocs: Documentation changesstyle: Code style changes (formatting, etc)refactor: Code refactoringtest: Adding or updating testschore: Maintenance tasks
Examples:
feat(search): add semantic email search
fix(auth): resolve token refresh issue
docs(readme): update installation instructions
test(email): add unit tests for email parser
- TypeScript: We use TypeScript for type safety
- ESLint: Run
npm run lintbefore committing - Prettier: Run
npm run format:writeto format code - Naming Conventions:
- Components: PascalCase (
EmailList.tsx) - Functions: camelCase (
fetchEmails()) - Constants: UPPER_SNAKE_CASE (
MAX_RETRIES) - Files: kebab-case for utils, PascalCase for components
- Components: PascalCase (
All contributions must include appropriate tests:
-
Unit Tests: For utility functions and isolated components
npm run test -
Integration Tests: For API routes and database operations
-
E2E Tests: For critical user flows
npm run test:e2e
Test Coverage: Aim for at least 70% coverage for new code
- Create a pull request with a clear title and description
- Link any related issues
- Ensure all CI checks pass
- Wait for review from maintainers
- Address any feedback
- Once approved, a maintainer will merge your PR
vectormail-ai/
├── src/
│ ├── app/ # Next.js app directory
│ │ ├── (auth)/ # Authentication routes
│ │ ├── api/ # API routes
│ │ └── mail/ # Mail client pages
│ ├── components/ # React components
│ │ ├── landing/ # Landing page components
│ │ ├── mail/ # Mail client components
│ │ └── ui/ # Reusable UI components
│ ├── lib/ # Utility functions
│ ├── server/ # Server-side code
│ │ └── api/ # tRPC routers
│ └── hooks/ # Custom React hooks
├── prisma/ # Database schema
├── e2e/ # End-to-end tests
├── docs/ # Documentation
└── public/ # Static assets
import { render, screen } from '@testing-library/react'
import { EmailList } from '@/components/mail/EmailList'
describe('EmailList', () => {
it('renders email items correctly', () => {
const emails = [{ id: '1', subject: 'Test', from: 'test@example.com' }]
render(<EmailList emails={emails} />)
expect(screen.getByText('Test')).toBeInTheDocument()
})
})import { test, expect } from "@playwright/test";
test("user can compose and send email", async ({ page }) => {
await page.goto("/mail");
await page.click("text=Compose");
await page.fill('[name="to"]', "recipient@example.com");
await page.fill('[name="subject"]', "Test Subject");
await page.click("text=Send");
await expect(page.locator("text=Email sent")).toBeVisible();
});When adding new features:
- Update relevant documentation in
/docs - Add inline code comments for complex logic
- Update the README if necessary
- Add JSDoc comments for public APIs
- Check existing Issues
- Email us at parbhat@parbhat.dev
We pledge to make participation in our project a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity, level of experience, nationality, personal appearance, race, religion, or sexual identity.
Positive behavior includes:
- Using welcoming and inclusive language
- Being respectful of differing viewpoints
- Gracefully accepting constructive criticism
- Focusing on what is best for the community
Unacceptable behavior includes:
- Trolling, insulting comments, and personal attacks
- Public or private harassment
- Publishing others' private information
- Other conduct which could be considered inappropriate
Contributors will be:
- Listed in our README
- Mentioned in release notes
- Given credit in the project
By contributing, you agree that your contributions will be licensed under the MIT License.
Thank you for making VectorMail better!