Agent skill · software engineering · personamanagmentlayer
php-expert
Expert-level PHP development with PHP 8+, Laravel, Composer, and modern best practices. Use when the user mentions Laravel, Composer, Symfony, PHPUnit, or PSR standards, or when the task involves PHP 8+ Features, Object-Oriented PHP, Modern PHP, or Constructor Property Promotion.
Why this skill is useful
Provides specific guidance on PHP 8+ features and Laravel best practices that the AI may not reliably generate on its own.
What it needs
About 3k tokens when loaded. Last updated 2026-03-30. 41 stars on the source repository.
What this skill does
PHP Expert Expert guidance for modern PHP development including PHP 8+ features, Laravel framework, Composer dependency management, and PHP best practices. Core Concepts PHP 8+ Features Union types and mixed type Named arguments Attributes (annotations) Constructor property promotion Match expressions Nullsafe operator JIT compiler Fibers (PHP 8.1+) Readonly properties and classes Object-Oriented PHP Classes and objects Interfaces and abstract classes Traits Namespaces Autoloading (PSR-4) Type declarations Visibility modifiers Modern PHP Strict types Return type declarations Property type declarations Enums (PHP 8.1+) First-class callable syntax Testing with PHPUnit Feature Tests Unit Tests Factories Best Practices Type Safety Dependency Injection PSR Standards PSR-1: Basic Coding Standard PSR-4: Autoloading Standard PSR-12: Extended Coding Style PSR-7: HTTP Message Interface Anti-Patterns to Avoid ❌ Not using strict types: Always declare(stricttypes=1) ❌ Fat controllers: Extract logic to services ❌ N+1 queries: Use eager loading ❌ No type declarations: Use types everywhere ❌ Ignoring PSR standards: Follow PSR-4, PSR-12 ❌ Direct DB queries in controllers: Use repositories ❌ Missing validation: Always validate input ❌ No tests: Write tests for critical code Reference Documentation Detailed material lives alongside this skill and is read on demand: Laravel Framework — Models, Controllers, Form Requests, API Resources, Eloquent Queries, Migrations, Jobs (Queues), Events and Listeners Modern PHP 8+ Syntax — Constructor Property Promotion, Named Arguments, Union Types and Mixed, Match Expression, Nullsafe Operator, Attributes (Annotations), Enums (PHP 8.1+), Readonly Properties and Classes Resources PHP Documentation: https://www.php.net/docs.php Laravel Documentation: https://laravel.com/docs Composer: https://getcomposer.org/ PSR Standards: https://www.php-fig.org/psr/ PHPUnit: https://phpunit.de/
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills personamanagmentlayer/php-expert