PHPackages                             php-etl/array-expression-language - 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. php-etl/array-expression-language

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

php-etl/array-expression-language
=================================

This library implements functions for manipulating array data in ExpressionLanguage

v0.4.2(2y ago)13.6kMITPHPPHP &gt;=8.2CI failing

Since Oct 4Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/php-etl/array-expression-language)[ Packagist](https://packagist.org/packages/php-etl/array-expression-language)[ RSS](/packages/php-etl-array-expression-language/feed)WikiDiscussions main Synced 3w ago

READMEChangelog (5)Dependencies (9)Versions (13)Used By (0)

Array Expression Language
=========================

[](#array-expression-language)

This package extends the [ExpressionLanguage](https://symfony.com/doc/current/components/expression_language.html) Symfony component to compile and evaluate arrays and iterables with custom functions.

[![Quality (PHPStan lvl 4)](https://github.com/php-etl/array-expression-language/actions/workflows/quality.yaml/badge.svg)](https://github.com/php-etl/array-expression-language/actions/workflows/quality.yaml)[![PHPUnit](https://github.com/php-etl/array-expression-language/actions/workflows/phpunit.yaml/badge.svg)](https://github.com/php-etl/array-expression-language/actions/workflows/phpunit.yaml)[![Infection](https://github.com/php-etl/array-expression-language/actions/workflows/infection.yaml/badge.svg)](https://github.com/php-etl/array-expression-language/actions/workflows/infection.yaml)[![PHPStan level 5](https://github.com/php-etl/array-expression-language/actions/workflows/phpstan-5.yaml/badge.svg)](https://github.com/php-etl/array-expression-language/actions/workflows/phpstan-5.yaml)[![PHPStan level 6](https://github.com/php-etl/array-expression-language/actions/workflows/phpstan-6.yaml/badge.svg)](https://github.com/php-etl/array-expression-language/actions/workflows/phpstan-6.yaml)[![PHPStan level 7](https://github.com/php-etl/array-expression-language/actions/workflows/phpstan-7.yaml/badge.svg)](https://github.com/php-etl/array-expression-language/actions/workflows/phpstan-7.yaml)[![PHPStan level 8](https://github.com/php-etl/array-expression-language/actions/workflows/phpstan-8.yaml/badge.svg)](https://github.com/php-etl/array-expression-language/actions/workflows/phpstan-8.yaml)[![PHP](https://camo.githubusercontent.com/eee10c38d951e11231bc64ca2118c70204253a3f8f5cc73a106eced5cd66c367/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f7068702d65746c2f61727261792d65787072657373696f6e2d6c616e6775616765)](https://camo.githubusercontent.com/eee10c38d951e11231bc64ca2118c70204253a3f8f5cc73a106eced5cd66c367/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f7068702d65746c2f61727261792d65787072657373696f6e2d6c616e6775616765)

Documentation
-------------

[](#documentation)

[See full Documentation](https://php-etl.github.io/documentation)

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

[](#installation)

```
composer require php-etl/array-expression-language

```

Usage
-----

[](#usage)

You can use these expressions in your configuration files as in the following example :

```
foo: '@=count(input["myArray"])'
```

List of available functions
---------------------------

[](#list-of-available-functions)

#### Generic functions

[](#generic-functions)

- `firstKey(array $array) : int|string|null`
- `lastKey(array $array) : int|string|null `
- `keyExists(string|int $key, array $array) : bool`
- `merge(array ...$arrays) : array`
- `count(Countable|array $value) : int`
- `combine(array $keys, array $values) : array`
- `iterableToArray(Traversable $iterator, bool $use_keys = true) : array`
- `map(callable $callback, iterable $source) : iterable`
- `reduce(callable $callback, iterable $source) : string`
- `list(int $length, mixed $value) : iterable`
- `arrayFilter(array $array, ?callable $callback = null) : array`
- `mapValues(array $input, iterable $values) : array`

#### Functions that can be used with `reduce`

[](#functions-that-can-be-used-with-reduce)

- `join(string $separator) : callable`

#### Functions that can be used with `map`

[](#functions-that-can-be-used-with-map)

- `extraxctData(string $path) : callable`

Functions that can be used with `arrayFilter`
---------------------------------------------

[](#functions-that-can-be-used-with-arrayfilter)

Any function can be used with this method as long as it returns true or false.

###  Health Score

39

—

LowBetter than 84% of packages

Maintenance53

Moderate activity, may be stable

Popularity18

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~30 days

Total

9

Last Release

1005d ago

PHP version history (2 changes)v0.1.x-devPHP &gt;=8.0

v0.2.0PHP &gt;=8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/144109625f8029112d56f43d08120cf03a0918ea3b4fd59ab53f09b02f630b00?d=identicon)[gplanchat](/maintainers/gplanchat)

---

Top Contributors

[![gplanchat](https://avatars.githubusercontent.com/u/152367?v=4)](https://github.com/gplanchat "gplanchat (22 commits)")[![sebprt](https://avatars.githubusercontent.com/u/47692802?v=4)](https://github.com/sebprt "sebprt (21 commits)")[![nicolas43000](https://avatars.githubusercontent.com/u/43703142?v=4)](https://github.com/nicolas43000 "nicolas43000 (11 commits)")[![clemzarch](https://avatars.githubusercontent.com/u/28787740?v=4)](https://github.com/clemzarch "clemzarch (6 commits)")[![JoMessina](https://avatars.githubusercontent.com/u/99172532?v=4)](https://github.com/JoMessina "JoMessina (2 commits)")[![programgames](https://avatars.githubusercontent.com/u/18596429?v=4)](https://github.com/programgames "programgames (1 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan, Rector

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/php-etl-array-expression-language/health.svg)

```
[![Health](https://phpackages.com/badges/php-etl-array-expression-language/health.svg)](https://phpackages.com/packages/php-etl-array-expression-language)
```

###  Alternatives

[solspace/craft-freeform

The most flexible and user-friendly form building plugin!

54681.3k18](/packages/solspace-craft-freeform)[typo3/cms

TYPO3 CMS is a free open source Content Management Framework initially created by Kasper Skaarhoj and licensed under GNU/GPL.

1.2k1.9M122](/packages/typo3-cms)[blackfire/player

A powerful web crawler and web scraper with Blackfire support

49617.1k](/packages/blackfire-player)[contao/core-bundle

Contao Open Source CMS

1231.6M2.8k](/packages/contao-core-bundle)[symfony/ux-autocomplete

JavaScript Autocomplete functionality for Symfony

645.9M39](/packages/symfony-ux-autocomplete)[open-dxp/opendxp

Content &amp; Product Management Framework (CMS/PIM)

9421.6k61](/packages/open-dxp-opendxp)

PHPackages © 2026

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