spatie/laravel-auto-discoverer
Fast, cached discovery of PHP structures in your codebase. Find classes, interfaces, traits, and enums by conditions like “implements interface” or “uses trait,” and get rich metadata. Ideal for automation, registration, and scanning in production.
PluginServiceProvider, ThemeRenderer). Reduces manual registration boilerplate.PaymentGateway implements Chargeable"). Integrate with health checks or CI pipelines.glob() + Reflection logic). Justifies OSS adoption over proprietary tools for PHP ecosystems.RegistersRoutes).ShouldBeTested.Serializable models").#[Deprecated]).Reflection scans in production.phpstan or psalm).nikic/php-parser or phpstan).For Executives: "This package eliminates technical debt from manual class discovery, enabling faster feature delivery and plugin ecosystems. For example, a plugin marketplace could auto-load extensions without manual configuration—reducing onboarding friction by 80%. The built-in caching ensures zero performance impact in production, and its open-source nature aligns with our cost-efficiency goals."
For Engineering:
*"Replace your custom glob() + Reflection hacks with a battle-tested, cache-optimized solution. Key benefits:
Discover::in(app_path())->implementing(Serializable::class)->get()).php artisan structure-scouts:cache.namespace === 'App'), parallel scanning, and chain resolution for inheritance.For Developers:
*"Say goodbye to foreach (glob(app_path('*/*.php'))) hell. This package gives you:
classes()->withAttribute(Cacheable::class)->sortBy(Sort::Name).isAbstract, extendsChain) for introspection.parallel().
Example: Find all #[ApiResource] classes in your API layer instantly."*How can I help you explore Laravel packages today?