spatie/or-else
Adds an OrElse trait that auto-creates “*OrElse” method variants for your class methods. These variants accept a fallback value that’s returned whenever the original method returns null or false, helping you avoid repetitive default-handling code.
|
Package
|
Score
|
Description
|
Stars
|
Likes
|
Forks
|
Downloads
|
Issues
|
Score
|
Opportunity
|
License
|
Last Release
|
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| spatie/query-string | 0.89 | Manipulate URLs by building and updating query strings in PHP. Toggle parameters or values, add JSON:API-style filters and sorts, and manage pagination. Useful for generating links and keeping state in apps without manual query parsing. | 161 | 162 | 9 | 19K | 0 | 2.0 | 28.8 | MIT | 5 years ago | |
| spatie/image | 0.89 | spatie/image provides an expressive, chainable PHP API for common image manipulation. Resize to fit a bounding box without altering aspect ratio, apply greyscale, adjust brightness and quality, rotate, sharpen, and save or overwrite images in just a few lines. Ideal for Laravel and PHP apps. | 1,367 | 1,389 | 143 | 4M | 0 | 40.9 | 56.6 | MIT | 2 days ago | |
| spatie/blink | 0.88 | spatie/blink is a tiny in-memory cache for PHP apps. Store values for the current request to avoid repeated work like duplicate queries or expensive calculations. Simple API, no persistence—perfect for per-request memoization in Laravel and beyond. | 167 | 167 | 18 | 405K | 0 | 5.0 | 46.7 | MIT | 3 years ago | |
| spatie/visit | 0.88 | Human-friendly curl for the terminal. Visit any URL and display its response with colorized output (HTML via bat, JSON via jq), plus status code and response time. Supports custom HTTP methods and options like following redirects. | 390 | 390 | 14 | 2 | 0 | 7.5 | 0.0 | — | 1 year ago | |
| spatie/ray | 0.88 | spatie/ray sends debug output from any PHP app to Ray, Spatie's desktop debugging app. Dump arrays, HTML, queries, and Markdown, measure performance, pause execution, and inspect output with the same syntax you use across Laravel, JavaScript, and more. | 624 | 627 | 102 | 2M | 0 | 35.7 | 55.7 | MIT | 1 day ago | |
| spatie/invade | 0.88 | Spatie's invade function lets you read, write, and call private properties and methods of any PHP object, including static ones, through a simple proxy—handy for testing or working with legacy code. | 341 | 343 | 20 | 7M | 0 | 24.7 | 64.6 | MIT | 2 weeks ago | |
| spatie/test-time | 0.87 | Control time in tests with Spatie TestTime—freeze or advance Carbon-based timestamps dynamically for time-sensitive assertions. Simplify testing date-dependent logic by manually adjusting time without altering real-world clocks. Works seamlessly with Carbon’s methods like addYear(), subDay(), or cus... | 208 | 208 | 9 | 246K | 0 | 5.2 | 42.4 | MIT | 2 years ago | |
| spatie/html-element | 0.87 | Generate dynamic HTML in PHP with a hyperscript-style API plus Emmet-like selectors. Build elements and attributes with a simple render helper (often wrapped as el()) to produce nested markup cleanly and programmatically, ideal for small view components. | 192 | 195 | 23 | 1K | 0 | 3.5 | 11.7 | MIT | 4 years ago | |
| spatie/craft-ray | 0.87 | Send debug output from Craft CMS to Ray, Spatie’s desktop debugging app. Inspect arrays, HTML, queries, and more with a consistent API, measure performance, and pause execution. Great for fast feedback across PHP and other languages. | 16 | 16 | 1 | 347 | 0 | 9.5 | 19.5 | MIT | 8 months ago | |
| spatie/server-side-rendering | 0.87 | Render JavaScript server-side from PHP with minimal setup. Works with any SSR-capable framework, supports V8Js or a Node-based engine, and lets you execute an entry script to return rendered HTML—ideal for adding SSR to existing PHP apps. | 633 | 638 | 34 | 12K | 0 | 7.4 | 17.9 | MIT | 11 months ago | |
| spatie/color | 0.87 | PHP library for color parsing, conversion, and comparison. Supports CSS named colors plus RGB/RGBA/ARGB, Hex, HSL/HSLA, HSB, CMYK, CIELab, and XYZ. Includes WCAG contrast ratio and Delta E distances (CIE76, CIE94, CIEDE2000). | 386 | 390 | 41 | 1M | 0 | 16.2 | 50.7 | MIT | 8 months ago | |
| spatie/http-status-check | 0.87 | CLI tool to crawl a website and report HTTP status codes for every link. Scan internal and optionally external URLs, control concurrency for speed, and export failing (non-2xx/3xx) links to a file for quick auditing. | 600 | 603 | 85 | 32 | 0 | 6.1 | 0.2 | MIT | 3 years ago | |
| spatie/url | 0.87 | Immutable URL parser/builder for PHP. Parse scheme, host, path and query, then fluently transform parts (withHost, withPath, withScheme) and manage query parameters. Supports allowed/sanitized schemes for safer URL handling. | 738 | 751 | 59 | 679K | 0 | 12.5 | 41.0 | MIT | 2 years ago | |
| spatie/menu | 0.87 | Fluent, extensible menu builder for Laravel. Compose navigation with a clean API, render as HTML, and customize output via presenters and macros. Supports active state handling, links, submenus, and easy integration with Blade and your app’s routing. | 754 | 763 | 100 | 58K | 0 | 15.8 | 26.2 | MIT | 1 year ago | |
| spatie/regex | 0.86 | Cleaner, safer wrapper around PHP’s preg_* functions. Provides Regex::match/matchAll/replace with MatchResult objects, easy access to groups, sensible defaults, and callback-based replacements—no by-reference variables or confusing false/null error handling. | 1,121 | 1,133 | 49 | 2M | 0 | 11.6 | 43.8 | MIT | 4 years ago | |
| cocur/vale | 0.85 | cocur/vale is a lightweight PHP value validation library. Define reusable rules to validate strings, numbers, arrays, and objects, and get clear, consistent results without pulling in a full framework—handy for DTOs, APIs, and input sanitization. | 14 | 14 | 1 | 3K | 0 | 0.7 | 32.1 | MIT | 11 years ago | |
| spatie/laravel-or-abort | 0.85 | Adds an OrAbort trait to Laravel models to abort with a chosen HTTP status when common calls fail (e.g., findOrAbort($id, 500) instead of returning null/false). Note: this package is no longer maintained. | 53 | 53 | 2 | 11 | 0 | 0.8 | 0.7 | MIT | 11 years ago | |
| spatie/fractalistic | 0.84 | Developer-friendly wrapper around League Fractal to transform API data with less boilerplate. Build resources, apply transformers, includes, and output arrays with a fluent API or one-liner syntax. Great for PHP projects; Laravel users may prefer laravel-fractal. | 383 | 385 | 32 | 429K | 0 | 17.2 | 44.3 | MIT | 8 months ago | |
| spatie/fork | 0.84 | Run PHP code concurrently with spatie/fork, which forks the main process into child tasks. Pass multiple closures to run at the same time, then collect results in order. Requires PHP 8 and the pcntl extension, and works in CLI only, not web contexts. | 1,050 | 1,052 | 120 | 310K | 0 | 35.1 | 40.1 | MIT | 20 hours ago | |
| spatie/laravel-blade | 0.84 | Add Blade to any PHP project with the standalone Blade engine from Spatie. Compile and render Blade templates outside Laravel, with an easy API, caching support, and configurable view paths—ideal for small apps, packages, or custom tooling. | 55 | 54 | 10 | 0 | 0 | 0.9 | — | MIT | 9 years ago |
How can I help you explore Laravel packages today?