Craft CMS PHP Standards

•
52
•

Enforces strict PHP coding standards and architectural patterns for Craft CMS 5 plugin and module development.

This skill provides a comprehensive framework for writing and maintaining production-ready PHP code within the Craft CMS 5 ecosystem. It extends official Craft guidelines with specific conventions for class organization, naming patterns for services and queue jobs, and advanced PHPDoc documentation including exception chains. By integrating with tools like PHPStan and ECS via DDEV, it ensures high code quality, handles complex data types, and enforces specific patterns for database queries and date manipulation tailored specifically for Craft CMS developers.

주요 기능

01Standardized class organization using project-specific section headers and property ordering
02Comprehensive PHPDoc enforcement for classes, methods, and properties including @throws chains
03Optimized control flow patterns emphasizing early returns and modern PHP match expressions
04Integration guidance for DDEV-based tooling including PHPStan, ECS, and Craft generators
05Strict naming conventions for services, queue jobs, records, and element actions
0652 GitHub stars

사용 사례

01Scaffolding and developing custom Craft CMS 5 plugins or modules with consistent architecture
02Refactoring legacy Craft codebases to meet modern static analysis and coding standards
03Conducting automated code reviews to ensure PHP 8.2+ compatibility and Craft core alignment