PHPackages                             php-standard-library/either-or-both - 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-standard-library/either-or-both

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

php-standard-library/either-or-both
===================================

Three-variant disjoint union type (Left/Right/Both) for values that may be present on either or both of two sides

6.2.1(2w ago)45.6k↓28.2%1MITPHPPHP ~8.4.0 || ~8.5.0

Since May 23Pushed 2w agoCompare

[ Source](https://github.com/php-standard-library/either-or-both)[ Packagist](https://packagist.org/packages/php-standard-library/either-or-both)[ Docs](https://php-standard-library.dev)[ RSS](/packages/php-standard-library-either-or-both/feed)WikiDiscussions next Synced 1w ago

READMEChangelog (2)Dependencies (5)Versions (4)Used By (1)

PHP Standard Library - EitherOrBoth
===================================

[](#php-standard-library---eitherorboth)

Three-variant disjoint union type (Left/Right/Both) for values that may be present on either or both of two sides.

---

- [Documentation](https://php-standard-library.dev)
- [Contributing](https://github.com/php-standard-library/php-standard-library/blob/next/CONTRIBUTING.md)
- [Create Pull Request](https://github.com/php-standard-library/php-standard-library/pulls)
- [Report an Issue](https://github.com/php-standard-library/php-standard-library/issues)

###  Health Score

50

—

FairBetter than 95% of packages

Maintenance96

Actively maintained with recent releases

Popularity30

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 66.7% 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

3

Last Release

17d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8489d7c85bfa7c637b8e13484f3f659652aea0568b6e7f9e66edeb0649b5a2f1?d=identicon)[azjezz](/maintainers/azjezz)

---

Top Contributors

[![azjezz](https://avatars.githubusercontent.com/u/29315886?v=4)](https://github.com/azjezz "azjezz (2 commits)")[![veewee](https://avatars.githubusercontent.com/u/1618158?v=4)](https://github.com/veewee "veewee (1 commits)")

---

Tags

botheithereither-or-boththeseunion-typeeitherunion typebotheither-or-boththese

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/php-standard-library-either-or-both/health.svg)

```
[![Health](https://phpackages.com/badges/php-standard-library-either-or-both/health.svg)](https://phpackages.com/packages/php-standard-library-either-or-both)
```

###  Alternatives

[phpro/soap-client

A general purpose SoapClient library

8955.9M52](/packages/phpro-soap-client)[php-soap/wsdl

Deals with WSDLs

173.8M18](/packages/php-soap-wsdl)[roave/backward-compatibility-check

Tool to compare two revisions of a public API to check for BC breaks

5963.6M72](/packages/roave-backward-compatibility-check)[veewee/reflecta

Unleash the Power of Optics in your code!

13367.2k6](/packages/veewee-reflecta)[php-soap/engine

SOAP engine design

273.7M32](/packages/php-soap-engine)[chemem/bingo-functional

A simple functional programming library.

687.0k3](/packages/chemem-bingo-functional)

PHPackages © 2026

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