supportpal/eloquent-model
Eloquent-style base Model for PHP/Laravel to build custom, non-database models. Supports accessors/mutators, attribute casting, guarded/fillable and hidden fields, appended attributes, and easy array/JSON conversion.
save() methods).save() logic must validate inputs.save() methods).Jenssegers\Model to test serialization, accessors, and mutators.save() methods handle persistence.App\Models\LegacyUser).Model::setConnection() or custom bootstrapping).Jenssegers\Model instead of Laravel’s Model to prevent service container collisions.save() logic.save()) must be manually maintained.README or wiki.dd() to inspect attribute transformations.| Risk | Impact | Mitigation |
|---|---|---|
| Package abandonment | Broken dependencies, security risks | Fork or switch to Eloquent if critical. |
| Attribute corruption | Invalid data in save() calls |
Strict input validation in mutators. |
| Serialization bugs | Inconsistent JSON/array output | Test edge cases (e.g., nested objects). |
| Laravel conflicts | Service container collisions | Isolate namespaces or avoid in Laravel. |
How can I help you explore Laravel packages today?