PHPackages                             componenta/array - 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. componenta/array

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

componenta/array
================

Array helper functions for Componenta packages

v1.0.0(1mo ago)091MITPHPPHP ^8.4

Since Jun 16Pushed 1mo agoCompare

[ Source](https://github.com/componenta/array)[ Packagist](https://packagist.org/packages/componenta/array)[ RSS](/packages/componenta-array/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (1)Dependencies (3)Versions (2)Used By (1)

Componenta Array
================

[](#componenta-array)

Standalone array helper functions for key checks, nested paths, filtering, mapping, sorting, grouping, recursive transforms, query-string building, and conversion to plain arrays.

Use this package when a library needs predictable array utilities without pulling in a larger collection component.

Installation
------------

[](#installation)

```
composer require componenta/array
```

Related Packages
----------------

[](#related-packages)

PackageWhy it matters here`componenta/arrayable``to_array()` consumes `ArrayableInterface` when an object exposes an array representation.`componenta/config`Often works with nested arrays and paths, while configuration access itself stays in `componenta/config`.Usage
-----

[](#usage)

```
use function Componenta\Array\array_get;
use function Componenta\Array\array_path;
use function Componenta\Array\array_set_path;

$data = ['user' => ['name' => 'Ada']];

$name = array_path($data, 'user.name');       // "Ada"
$missing = array_get($data, 'email', 'none'); // "none"

array_set_path($data, 'user.email', 'ada@example.com');
```

Helper Groups
-------------

[](#helper-groups)

Lookup helpers:

- `array_has`
- `array_has_any`
- `array_has_all`
- `array_missing`
- `array_get`
- `array_get_typed`
- `array_get_or_fail`
- `array_path`
- `array_path_or_fail`

Mutation helpers:

- `array_put`
- `array_add`
- `array_set`
- `array_set_path`
- `array_forget`
- `array_forget_path`
- `array_pull`

Selection and transformation:

- `array_only`
- `array_except`
- `array_where`
- `array_map_with_keys`
- `array_map_recursive`
- `array_filter_null`
- `array_pluck`
- `array_group_by`
- `array_key_by`
- `array_partition`

Structure helpers:

- `array_flatten`
- `array_collapse`
- `array_dot`
- `array_undot`
- `array_divide`
- `array_wrap`
- `array_chunk_by`

Ordering and set-like helpers:

- `array_sort`
- `array_sort_recursive`
- `array_shuffle`
- `array_random`
- `array_unique_by`
- `array_diff_assoc_recursive`
- `array_merge_recursive_distinct`

Predicate helpers:

- `array_contains`
- `array_first`
- `array_last`
- `array_find_key`
- `array_every`
- `array_some`
- `array_exists`
- `array_is_assoc`
- `is_accessible`

Other helpers:

- `array_join`
- `array_take`
- `array_skip`
- `array_query`
- `to_array`

Conversion
----------

[](#conversion)

`to_array()` understands arrays, objects, iterators, iterator aggregates, and `Componenta\Arrayable\Arrayable`.

The package does not define serialization policy for domain objects. If an object has application-specific output rules, expose them through `Arrayable` or a serializer layer.

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance91

Actively maintained with recent releases

Popularity7

Limited adoption so far

Community8

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

Unknown

Total

1

Last Release

43d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/20490712?v=4)[Andrey Shelamkoff](/maintainers/Shelamkoff)[@Shelamkoff](https://github.com/Shelamkoff)

---

Top Contributors

[![Shelamkoff](https://avatars.githubusercontent.com/u/20490712?v=4)](https://github.com/Shelamkoff "Shelamkoff (1 commits)")

###  Code Quality

TestsPest

### Embed Badge

![Health badge](/badges/componenta-array/health.svg)

```
[![Health](https://phpackages.com/badges/componenta-array/health.svg)](https://phpackages.com/packages/componenta-array)
```

###  Alternatives

[utopia-php/messaging

A simple, light and advanced PHP messaging library

23236.1k6](/packages/utopia-php-messaging)

PHPackages © 2026

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