citrus-framework/intersection

php switch library

Maintainers

Package info

github.com/citrus-framework/intersection

pkg:composer/citrus-framework/intersection

Statistics

Installs: 855

Dependents: 4

Suggesters: 0

Stars: 1

Open Issues: 1

v1.0.3 2024-07-02 19:18 UTC

This package is auto-updated.

Last update: 2026-03-01 00:30:38 UTC


README

php switch library

Install

composer require citrus-framework/intersection

USAGE

$value = 'admin';
$result = Intersection::fetch($value, [
    'user' => function () {
        return 'John';
    },
    'admin' => function () {
        return 'Alice';
    },
    'owner' => 'Michael',
], true);

// $result: 'Alice'