This repository contains guides of best practices for software development, covering processes, code standards, and tools.
- Project Management
- Git Processes
- Technology Guides
- Code Standards
- Quality Assurance
- Infrastructure & Security
These guides detail the processes and standards for project and task management:
- Task Management (SOP) - Complete guide for task workflow, including story points, stages, and responsibilities
- ESLint & Prettier Configuration - Code style and quality enforcement setup
These guides detail the processes that the team should follow when using Git, ensuring consistency, quality, and efficiency in software development:
- Branches - Structure, naming, and workflow with branches
- Commits - Standards for commit messages and best practices
- Pull Requests - Creation, review, and merging of pull requests
- Code Review - Guidelines for effective code review
Each file contains specific best practices for a technology:
- JavaScript - Best practices guide for JavaScript
- TypeScript - Best practices guide for TypeScript
- Vue.js - Best practices guide for Vue.js
- Nuxt.js - Best practices guide for Nuxt.js
- Python - Best practices guide for Python
- .NET - Best practices guide for .NET development
- Supabase - Best practices guide for Supabase usage with Nuxt and TypeScript
- C++ - Best practices guide for C++ development
- Unity - Best practices guide for Unity game development
- Unreal Engine - Best practices guide for Unreal Engine development
- Godot - Best practices guide for Godot Engine and GDScript
The following code standards are applicable to all projects:
-
Function Design
- Functions should do only one thing and do it well
- Keep functions small (ideally less than 20 lines)
- Functions should have a single level of abstraction
-
Variable Naming
- Use names that reveal intent
- Use pronounceable names
- Use searchable names
- Avoid encodings
-
Class Design
- Follow the Single Responsibility Principle
- Encapsulate related data and behavior
- Maintain high cohesion
-
Conditional Logic
- Use descriptive variables to explain complex conditions
- Extract complex conditions into well-named functions or variables
- Replace magic numbers with named constants
- Group related conditions to express business logic
- Avoid deep nesting of conditionals
- Consider using early returns to simplify logic
- God Objects/Classes
- Magic Numbers/Strings
- Deep Nesting
- Complex Inline Conditions
- Write unit tests for all new code
- Maintain test coverage above 80%
- Follow the AAA pattern (Arrange, Act, Assert)
- Use meaningful test descriptions
- Test success and failure cases
- Mock external dependencies appropriately
- Keep tests independent and isolated
- Write integration tests for critical paths
- Use appropriate testing frameworks (pytest for Python, Jest for TypeScript, Pest for PHP)
- Implement E2E tests for critical user journeys
- Keep README files updated
- Document setup and installation procedures
- Include API documentation for public interfaces
- Add inline comments for complex logic
- Document configuration options
- Keep documentation close to the code it describes
- Include examples for common use cases
- Document significant changes
- Maintain a CHANGELOG
- Include troubleshooting guides for common issues
- Follow OWASP security guidelines
- Implement proper authentication and authorization
- Sanitize all user inputs (trim, escape, validate)
- Use environment variables for sensitive data
- Implement proper session management
- Use HTTPS for all network communications
- Regular security dependency updates
- Implement rate limiting where appropriate
- Use prepared statements for database queries
- Implement proper CORS policies: Don't use '*'
- Optimize database queries
- Implement caching strategies
- Minimize HTTP requests
- Use appropriate data structures
- Implement pagination for large data sets
- Optimize assets (images, scripts, styles)
- Use lazy loading where appropriate
- Monitor memory usage
- Profile code for bottlenecks
- Consider scalability in design decisions
- Follow WCAG 2.1 guidelines
- Use semantic HTML elements
- Provide alternative text for images
- Ensure keyboard navigation
- Maintain proper color contrast
- Support screen readers
- Implement ARIA labels when necessary
- Test with accessibility tools
- Support text resizing
- Provide focus indicators
- Implement proper error handling
- Add logging and monitoring
- Use circuit breakers for external services
- Implement retry mechanisms
- Handle network failures gracefully
- Implement proper backup strategies
- Monitor system health
- Have fallback mechanisms
- Implement proper validation
- Use feature flags for risky changes
- Follow SOLID principles
- Keep code modular and loosely coupled
- Use dependency injection
- Maintain consistent coding style
- Keep dependencies updated
- Remove unused code and dependencies
- Write self-documenting code
- Use appropriate abstraction layers
- Maintain proper folder structure
- Regular code refactoring