veewee/reflecta
Reflecta is a PHP library for fast, reflection-based class inspection, letting you read properties, methods, and attributes without instantiating objects. Useful for building analyzers, mappers, and framework tooling.
ReflectionClass calls.Consider it when:
Look elsewhere when:
nikic/php-parser, Roave/BetterReflection, Symfony PropertyInfo, or Laravel’s existing reflection utilities already cover the use case.Executive summary: Reflecta is a small MIT-licensed PHP reflection library that can accelerate internal developer tooling and attribute-driven package features. It is a low-cost, low-blast-radius enabler, not a platform bet. Given its early-stage adoption signals, treat it as a pilot dependency behind an internal abstraction and avoid using it in customer-facing critical paths.
Engineering summary: It offers type-safe wrappers, a fluent API, PHP 8 union/intersection type support, and attribute inspection, which can reduce reflection boilerplate in codegen, analysis, and Laravel package tooling. The trade-off is low community adoption and maintenance risk. Mitigate by pinning the version, isolating it behind an adapter, adding contract tests, and retaining native reflection as a fallback.
How can I help you explore Laravel packages today?