genealabs/laravel-casts
GeneaLabs Laravel Casts adds flexible custom attribute casting to Eloquent models, making it easy to map database columns to value objects, DTOs, and other PHP classes. Keeps model code clean and cast logic reusable, testable, and simple to configure.
|
Package
|
Score
|
Description
|
Stars
|
Likes
|
Forks
|
Downloads
|
Issues
|
Score
|
Opportunity
|
License
|
Last Release
|
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| yuwuhsien/laravel-bcmath-cast | 0.89 | Laravel Eloquent casts for PHP 8.4's BCMath\Number object, turning model attributes into arbitrary-precision decimals so you can use natural operators like +, -, and * directly while keeping money math exact. Requires PHP 8.4+ and Laravel 12+. | 2 | 2 | 0 | 2K | 0 | 15.7 | 44.2 | MIT | 3 months ago | |
| jessarcher/laravel-castable-data-transfer-object | 0.88 | A Laravel package that lets Eloquent models cast attributes directly to data transfer objects, keeping structured data typed and clean while handling JSON serialization automatically. Ideal for replacing loose arrays with explicit DTO classes. | 325 | 333 | 22 | 2K | 3 | 1.7 | 8.3 | MIT | 3 years ago | |
| bgaze/laravel-kvstore | 0.87 | bgaze/laravel-kvstore provides a simple, database-backed key-value store for Laravel applications. Store and retrieve arbitrary values—strings, arrays, objects—through an intuitive API with dot-notation support, caching, and easy integration for app settings, preferences, and small configuration dat... | 19 | — | 0 | — | 0 | 16.9 | — | MIT | 2 months ago | |
| runn/valueobjects | 0.87 | Runn ValueObjects gives you a lightweight foundation for immutable PHP value objects, with typed base classes for strings, integers, booleans and arrays, validation helpers, and Eloquent casts to keep domain values consistent. | 9 | 9 | 2 | 18 | 1 | 0.3 | 6.2 | LGPL-3.0 | — | |
| nwidart/laravel-videoable | 0.87 | Laravel Videoable provides a Videoable trait and polymorphic video model to associate videos with any Eloquent model, making it easy to store and retrieve video records for posts, products, and other Laravel resources. | 18 | — | 10 | — | 0 | 0.7 | — | MIT | 8 years ago | |
| vkovic/laravel-custom-casts | 0.87 | vkovic/laravel-custom-casts provides reusable, class-based custom attribute casts for Laravel Eloquent models, keeping get/set and serialization logic organized, testable, and out of your models—ideal for value objects, arrays, and other complex attribute transformations. | 217 | 217 | 20 | 2K | 2 | 2.4 | 14.9 | MIT | 5 years ago | |
| michael-rubel/laravel-value-objects | 0.87 | Laravel Value Objects offers an abstract base class and Eloquent casts for turning model attributes into immutable value objects, with validation, comparison helpers, and PHP 8 support for cleaner, type-safe domain code. | 205 | 205 | 18 | 158 | 1 | 2.2 | 3.8 | MIT | 1 year ago | |
| hnhdigital-os/laravel-model-schema | 0.87 | Laravel Model Schema adds schema introspection to Eloquent models, letting you read column names, types, and related metadata directly from the model. Handy for generating forms, filters, validation rules, and admin scaffolding without querying the database manually. | 12 | 12 | 0 | 0 | 0 | 0.4 | — | MIT | 3 years ago | |
| n7olkachev/laravel-computed-properties | 0.86 | Add computed properties to your Laravel Eloquent models, calculated on the fly like accessors but excluded from the database. Keep models lean, reuse derived values across queries and serialization, and write less boilerplate. | 187 | — | 8 | — | 0 | 1.2 | — | — | 8 years ago | |
| andrey-helldar/laravel-roles | 0.86 | A lightweight Laravel package for managing user roles, offering a simple way to define roles and assign them to Eloquent models through a minimal API. Low adoption and limited documentation, so verify maintenance and compatibility before using in production. | 12 | 10 | 2 | 0 | 0 | 0.2 | — | MIT | 6 years ago | |
| neuecommerce/model-casts | 0.86 | — | 0 | 0 | 0 | 4K | 0 | 0.0 | 49.3 | MIT | — | |
| lionix/castable-request | 0.86 | Laravel package for casting incoming request data into typed objects and structured values, helping keep controllers clean and reducing manual array handling when working with validated input. | 23 | 23 | 0 | 281 | 0 | 18.2 | 17.7 | MIT | 1 month ago | |
| cviebrock/eloquent-typecast | 0.86 | — | 24 | 26 | 1 | 935 | 0 | 0.2 | 21.9 | MIT | — | |
| nwidart/laravel-normalizer | 0.86 | A Laravel package for normalizing data into consistent, predictable formats. Define custom normalizers to clean and transform input, making validation and storage simpler across your application. | 12 | — | 2 | — | 0 | 0.4 | — | MIT | 10 years ago | |
| folklore/eloquent-json-schema | 0.86 | Generate JSON Schema definitions directly from your Eloquent models. This package inspects attributes, casts, and relationships to build accurate schemas, making it easy to document APIs, validate payloads, and generate typed clients. | 3 | 3 | 1 | 1 | 0 | 0.0 | 1.3 | — | — | |
| cocur/vale | 0.86 | 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 | |
| michael-rubel/laravel-formatters | 0.85 | Laravel Formatters provides a clean, extensible set of formatter classes for common tasks like money, phone numbers, names, dates, and more. Formatters auto-resolve through the container and support method chaining, making consistent formatting simple throughout your app. | 94 | 94 | 7 | 409 | 0 | 1.2 | 10.0 | MIT | 1 year ago | |
| anourvalar/eloquent-serialize | 0.85 | Serialize and restore Eloquent query builders with ease. Capture chained queries including eager loading, where clauses, and limits, then unserialize later to run them. Supports Laravel 6 through 12. | 117 | 116 | 14 | 6M | 0 | 28.6 | 63.6 | MIT | 1 month ago | |
| based/laravel-typescript | 0.85 | based/laravel-typescript generates TypeScript definitions from Laravel models, resources, and routes, keeping frontend and backend types in sync via artisan commands and configurable output. | 396 | 399 | 53 | 1K | 10 | 6.9 | 13.1 | MIT | 5 years ago | |
| phl/laravel-sti | 0.85 | phl/laravel-sti brings Single Table Inheritance to Laravel Eloquent. Map multiple model subclasses to one database table using a type column, with automatic class resolution, scoped queries, and familiar Eloquent relationships and behavior for cleaner hierarchical models instead of separate tables. | 17 | 17 | 0 | 0 | 1 | 0.2 | — | MIT | 6 years ago |
How can I help you explore Laravel packages today?