PHPackages                             chriha/data-objects - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. chriha/data-objects

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

chriha/data-objects
===================

A PHP package to create immutable data objects with validation and transformation capabilities.

v1.0.1(8mo ago)010MITPHPPHP ^8.3CI passing

Since Sep 16Pushed 8mo agoCompare

[ Source](https://github.com/ClipMyHorseTV/data-objects)[ Packagist](https://packagist.org/packages/chriha/data-objects)[ RSS](/packages/chriha-data-objects/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)Dependencies (8)Versions (3)Used By (0)

Data Objects
============

[](#data-objects)

A PHP project for working with flexible data objects, supporting dynamic properties and array initialization.

Features
--------

[](#features)

- **Dynamic Properties:** Easily set and get properties on data objects.
- **Array Initialization:** Instantiate objects with an associative array of properties.
- **Extensible:** Create your own data object classes by extending the base `DataObject`.

Example Usage
-------------

[](#example-usage)

```
use ClipMyHorseTV\DataObject;
use ClipMyHorseTV\DataObjects\Attributes\MapFrom;

class Person extends DataObject
{
    #[MapFrom('name_attr')]
    public string $name;

    public int $age;
}

$person = Person::from(['name_attr' => 'Alice', 'age' => 30]);
echo $person->name; // Alice
echo $person->age;  // 30
```

Running Tests
-------------

[](#running-tests)

This project uses [PestPHP](https://pestphp.com/) for testing.

To run the tests:

```
composer install
./vendor/bin/pest
```

Directory Structure
-------------------

[](#directory-structure)

- `src/` - Source code for data objects
- `tests/` - PestPHP test suite

Requirements
------------

[](#requirements)

- PHP 8.3+
- Composer

License
-------

[](#license)

MIT

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance61

Regular maintenance activity

Popularity5

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

244d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0a593d81eb5101c5d9500de7203ccb540930b398f2dc342b0bb10db297cad886?d=identicon)[chriha](/maintainers/chriha)

---

Top Contributors

[![chriha](https://avatars.githubusercontent.com/u/53882?v=4)](https://github.com/chriha "chriha (8 commits)")

###  Code Quality

TestsPest

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/chriha-data-objects/health.svg)

```
[![Health](https://phpackages.com/badges/chriha-data-objects/health.svg)](https://phpackages.com/packages/chriha-data-objects)
```

###  Alternatives

[illuminate/support

The Illuminate Support package.

582107.1M34.5k](/packages/illuminate-support)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)[illuminate/session

The Illuminate Session package.

9937.4M753](/packages/illuminate-session)[illuminate/pagination

The Illuminate Pagination package.

10532.5M862](/packages/illuminate-pagination)[illuminate/broadcasting

The Illuminate Broadcasting package.

7126.5M178](/packages/illuminate-broadcasting)[illuminate/redis

The Illuminate Redis package.

8314.0M314](/packages/illuminate-redis)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
