From superpowers-laravel
Implements Laravel interfaces and dependency injection to decouple code; binds implementations in service container for testing and flexibility.
How this skill is triggered — by the user, by Claude, or both
Slash command
/superpowers-laravel:interfaces-and-diThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Define narrow interfaces and inject them where needed. Bind concrete implementations in a service provider.
Define narrow interfaces and inject them where needed. Bind concrete implementations in a service provider.
interface Slugger { public function slug(string $s): string; }
final class AsciiSlugger implements Slugger {
public function slug(string $s): string { /* ... */ }
}
$this->app->bind(Slugger::class, AsciiSlugger::class);
Benefits: easier testing (mock interfaces), clearer contracts, swap implementations without touching consumers.
npx claudepluginhub jpcaparas/superpowers-laravel --plugin superpowers-laravelSOLID principles for Laravel 12 and PHP 8.5. Files < 100 lines, interfaces separated, PHPDoc mandatory. Auto-detects Laravel and FuseCore architecture.
Provides production-grade, idiomatic Laravel solutions with clean architecture, security best practices, performance optimizations, and modern standards for Laravel 10/11+. Use for features, refactoring, APIs, auth, services, DB interactions, and code reviews.
Designing loosely coupled code through dependency injection, reducing testability barriers and hidden dependencies.