Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Php Enum Laravel Package

myclabs/php-enum

myclabs/php-enum brings SplEnum-style enums to PHP. Define enum classes, get autogenerated static constructors, validate values, compare instances, list possible values, and use enums as parameter/return types with extra methods—without a PHP extension.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

The package provides a robust enum implementation for PHP versions prior to 8.1, filling a critical gap in type-safe enum support. For Laravel projects running PHP <8.1, it integrates seamlessly with Laravel's type-hinting and DI systems, enabling clean controller/service method signatures and validation logic. However, for Laravel 9+ (which requires PHP 8.0+), native PHP enums are the superior choice, making this package largely obsolete for new projects. Integration feasibility is high for legacy PHP environments but becomes a technical debt risk for projects planning PHP 8.1+ upgrades. Key technical risks include: 1) potential

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport