php-standard-library/option
Option type for PHP with Some/None to replace nullable values with explicit presence semantics. Helps avoid null checks, clarifies intent, and models optional data safely. Part of PHP Standard Library; see docs and contributing links.
|
Package
|
Score
|
Description
|
Stars
|
Likes
|
Forks
|
Downloads
|
Issues
|
Score
|
Opportunity
|
License
|
Last Release
|
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| php-standard-library/php-standard-library | 0.84 | PSL is a modern standard library for PHP 8.4+, inspired by HHVM’s HSL. It offers consistent, well-typed APIs for async, collections, I/O, networking, crypto, terminal UI, and more—safer alternatives to built-ins with predictable errors and async-ready design. | 1,543 | 1,544 | 87 | 254K | 21 | 46.2 | 44.0 | MIT | 2 weeks ago | |
| prewk/option | 0.83 | Lightweight Option type for PHP providing Some/None to avoid nulls. Adds map/flatMap/filter, unwrap with defaults, and safe chaining inspired by functional programming. Handy for Laravel and general PHP codebases where nullable values cause bugs. | 47 | 47 | 9 | 34K | 0 | 1.2 | 41.2 | NOASSERTION | — | |
| phpoption/phpoption | 0.82 | PhpOption brings an Option type to PHP, helping you avoid null-related errors by making “value or none” explicit. Use Some and None to model optional results, write safer APIs, and handle missing values deliberately with a clean, functional-style API. | 2,677 | 2,701 | 67 | 12M | 1 | 33.8 | 56.7 | Apache-2.0 | 5 months ago | |
| imanghafoori/laravel-nullable | 0.80 | — | 151 | 151 | 10 | 19K | 2 | 3.1 | 29.2 | MIT | 1 year ago | |
| spatie/laravel-options | 0.80 | Generate unified select option lists in Laravel from enums, Eloquent models, states, and arrays. Spatie laravel-options converts sources to a consistent label/value structure, supports customization via config, and makes building dropdowns and filters faster and cleaner. | 251 | 254 | 9 | 16K | 0 | 22.3 | 28.8 | MIT | 1 month ago | |
| creavo/option-bundle | 0.79 | Symfony bundle to store and retrieve application options/settings via a service, Twig helper, or console commands. Persists values in Doctrine, supports typed options, optional eager loading, and PSR-16 simple cache for faster reads. | 0 | 0 | 0 | 0 | 0 | 5.1 | — | — | 2 years ago | |
| widmogrod/php-functional | 0.78 | Functional programming toolkit for PHP with immutable data structures, monads and typed abstractions. Includes Option/Either/Try, collections, pattern matching, and helpers for safer, composable code. Useful for DDD, CQRS and FP-style application architecture. | 369 | 374 | 32 | 217K | 7 | 29.0 | 46.8 | MIT | 1 year ago | |
| php-standard-library/either-or-both | 0.78 | EitherOrBoth provides a three-variant union type for PHP: Left, Right, or Both. Model values that may exist on either side or simultaneously, with a clear, type-safe API for representing and handling these outcomes. | 4 | 3 | 0 | 3K | 0 | 20.5 | 21.2 | MIT | 2 weeks ago | |
| patrickschur/language-detection | 0.78 | Detect the language of any text in Laravel/PHP with fast, lightweight language identification. Supports multiple languages, simple API, and easy framework integration—ideal for auto-tagging content, localization workflows, and routing based on user input. | 855 | 862 | 84 | 144K | 7 | 15.0 | 32.4 | MIT | 1 year ago | |
| kirkbushell/eloquence | 0.77 | — | 574 | 578 | 56 | 22K | 1 | 5.7 | 22.1 | MIT | 1 year ago | |
| cubicmushroom/valueobjects | 0.77 | A small PHP package providing lightweight Value Object classes to model immutable domain values (e.g., IDs, money, email, dates) with validation and type-safety. Useful for cleaner Laravel apps and DDD-style codebases. | 0 | 0 | 0 | 0 | 0 | 0.0 | — | MIT | — | |
| funeralzone/valueobjects | 0.77 | PHP 7.1+ value object toolkit for fundamental scalar-based VOs. Provides traits for strings/ints/etc, enums via constants, easy native serialization (fromNative/toNative), and encourages domain validation logic. Includes extension library for complex objects. | 66 | 66 | 7 | 18K | 2 | 6.3 | 33.7 | MIT | 5 years ago | |
| open-southeners/extended-php | 0.76 | Extended PHP helpers for modern apps: adds convenient functions, utilities, and small enhancements that complement core PHP to reduce boilerplate and speed up everyday development. Lightweight, easy to drop into existing projects. | 0 | 0 | 0 | 82 | 0 | 15.2 | 28.4 | MIT | 7 months ago | |
| php-standard-library/default | 0.76 | Provides a DefaultInterface for PHP classes to expose standardized “default” instances. Helps ensure consistent default construction across libraries and apps with a simple, shared contract. | 1 | 1 | 0 | 32K | 0 | 21.2 | 64.8 | MIT | 2 weeks ago |
How can I help you explore Laravel packages today?