PHPackages                             aeris/fn - 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. aeris/fn

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

aeris/fn
========

Functional utility library

v1.4.0(10y ago)13.9k1PHP

Since Aug 4Pushed 10y ago6 watchersCompare

[ Source](https://github.com/aerisweather/Fn)[ Packagist](https://packagist.org/packages/aeris/fn)[ RSS](/packages/aeris-fn/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (1)Versions (5)Used By (1)

Fn
==

[](#fn)

Functional utility library for PHP.

API
---

[](#api)

### partial

[](#partial)

### compose

[](#compose)

### identity

[](#identity)

### constant

[](#constant)

### always

[](#always)

### never

[](#never)

### cat

[](#cat)

### moreThanOrEqualTo

[](#morethanorequalto)

### lessthan

[](#lessthan)

### equalTo

[](#equalto)

### notEqualTo

[](#notequalto)

### even

[](#even)

### odd

[](#odd)

### both

[](#both)

### invoker

[](#invoker)

### invokeAll

[](#invokeall)

### invoke

[](#invoke)

### negate

[](#negate)

### conditional

[](#conditional)

### doWhen

[](#dowhen)

### errorThrower

[](#errorthrower)

### conditionalThrower

[](#conditionalthrower)

### throwWhen

[](#throwwhen)

### throwError

[](#throwerror)

### resolve

[](#resolve)

### resolver

[](#resolver)

### whenSetInvoker

[](#whensetinvoker)

### keySetChecker

[](#keysetchecker)

### isKeySet

[](#iskeyset)

### accessor

[](#accessor)

### cb

[](#cb)

### zip

[](#zip)

### mapAssoc

[](#mapassoc)

### pick

[](#pick)

### pluck

[](#pluck)

Plucks a property from a collection of associative arrays.

eg:

```
	Fn\pluck([
			['name' => 'moe', 'age' => 45],
			['name' => 'larry', 'age' => 55],
			['name' => 'curly', 'age' => 65]
		], 'name');
  // --> ['moe', 'larry', 'curly']
```

### concat

[](#concat)

Add a value to an array, or merge a set of values.

```
    Fn\concat(['a', 'b'], 'c');  				  // ['a', 'b', 'c']
    Fn\concat(['a', 'b'], ['c', 'd']);  	// ['a', 'b', 'c', 'd']
```

### any

[](#any)

Returns true if any item in the array passes a predicate

#### Example:

[](#example)

```
Fn\any([1, 3, 4, 5, 9], Fn\even()) // true
Fn\any([1, 3, 5, 9], Fn\even()) // false
```

### all

[](#all)

Returns true if every item in the array passes a predicate

#### Example:

[](#example-1)

```
Fn\all([1, 3, 5, 9], Fn\odd()) // true
Fn\all([1, 3, 4, 5, 9], Fn\even()) // false
```

### joinOr

[](#joinor)

### joinAnd

[](#joinand)

### factoryMap

[](#factorymap)

### factory

[](#factory)

### caller

[](#caller)

### countWhere

[](#countwhere)

### reduceAssoc

[](#reduceassoc)

### times

[](#times)

Invoke a callable some number of times.

```
Fn\times(3, function($i) {
	echo "call #$i";
})

// call 1
// call 2
// call 3
```

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity66

Established project with proven stability

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

Total

4

Last Release

3924d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f62ce003cf97458c12d531fc991ed04bec11c735bba4c37cff0190221c1b53db?d=identicon)[eschwartz](/maintainers/eschwartz)

### Embed Badge

![Health badge](/badges/aeris-fn/health.svg)

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

PHPackages © 2026

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