giacomomasseron / php-clean-architecture
PHP version of the Clean Architecture by Robert C. Martin (Uncle Bob)
Fund package maintenance!
Giacomo Masseroni
Requires (Dev)
- friendsofphp/php-cs-fixer: dev-master
- pestphp/pest: ^3.0
- pestphp/pest-plugin-arch: ^3.0
- pestphp/pest-plugin-type-coverage: ^3.2
- phpstan/extension-installer: ^1.3
- phpstan/phpstan: 2.1.x-dev
- phpstan/phpstan-deprecation-rules: ^2.0
- phpstan/phpstan-phpunit: ^2.0
- rector/rector: ^2.0
This package is auto-updated.
Last update: 2025-08-22 15:56:29 UTC
README
Implements Clean Architecture as described by Robert C. Martin (Uncle Bob) here
Clean Architecture.
This package uses the concept of Use Cases.
Installation
You can install the package via composer:
composer require giacomomasseron/php-clean-architecture
Usage
If you want to create a use case, you can create a class that extends \GiacomoMasseroni\FireAndForget\PHPCleanArchitecture
and implement the handle
method:
class DoSomethingUseCase extends GiacomoMasseroni\PHPCleanArchitecture\BaseUseCase
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.