PHPackages                             wpdesk/wp-show-decision - 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. wpdesk/wp-show-decision

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

wpdesk/wp-show-decision
=======================

1.1.0(2y ago)08.4k1PHPPHP &gt;=7.4CI failing

Since May 24Pushed 1mo agoCompare

[ Source](https://github.com/WP-Desk/wp-show-decision)[ Packagist](https://packagist.org/packages/wpdesk/wp-show-decision)[ RSS](/packages/wpdesk-wp-show-decision/feed)WikiDiscussions master Synced yesterday

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

[![Latest Stable Version](https://camo.githubusercontent.com/152b33852e732a56e5debff95c62c10dd43dc9ec66b9311335a6c6049f2a2ddc/68747470733a2f2f706f7365722e707567782e6f72672f77706465736b2f77702d73686f772d6465636973696f6e2f762f737461626c65)](https://packagist.org/packages/wpdesk/wp-show-decision)[![Total Downloads](https://camo.githubusercontent.com/f75b7b950456314bd83eb8d81e89f86d63f2ac28a40870dce024cd431c6640bb/68747470733a2f2f706f7365722e707567782e6f72672f77706465736b2f77702d73686f772d6465636973696f6e2f646f776e6c6f616473)](https://packagist.org/packages/wpdesk/wp-show-decision)[![Latest Unstable Version](https://camo.githubusercontent.com/42608fe9860040cb9ddd16ac9931344c611c15ea8bc3e8ff2531dd08493ae5a2/68747470733a2f2f706f7365722e707567782e6f72672f77706465736b2f77702d73686f772d6465636973696f6e2f762f756e737461626c65)](https://packagist.org/packages/wpdesk/wp-show-decision)[![License](https://camo.githubusercontent.com/40e71f55955fbd113f58ed6cca70109de223f678cf496b865c526f656c68b3d1/68747470733a2f2f706f7365722e707567782e6f72672f77706465736b2f77702d73686f772d6465636973696f6e2f6c6963656e7365)](https://packagist.org/packages/wpdesk/wp-show-decision)

wp-show-decision
================

[](#wp-show-decision)

Small library for deciding whether something should be displayed in WordPress.

Each strategy implements `WPDesk\ShowDecision\ShouldShowStrategy` and exposes one method:

```
public function shouldDisplay(): bool;
```

Requirements
------------

[](#requirements)

- PHP 7.4+

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

[](#installation)

```
composer require wpdesk/wp-show-decision
```

Usage
-----

[](#usage)

```
use WPDesk\ShowDecision\GetStrategy;

$strategy = new GetStrategy(
	[
		[ 'page' => 'wc-settings', 'tab' => 'shipping' ],
		[ 'page' => 'my-plugin' ],
	]
);

if ( $strategy->shouldDisplay() ) {
	// Show something.
}
```

Available Strategies
--------------------

[](#available-strategies)

- `GetStrategy` - matches `$_GET` parameters. Inner array means `AND`, outer array means `OR`.
- `PostTypeStrategy` - matches a WordPress post type.
- `ConstantDefinedStrategy` - true when a constant is defined.
- `ConstantNotDefinedStrategy` - true when a constant is not defined.
- `AndStrategy` - combines strategies with `AND`.
- `OrStrategy` - combines strategies with `OR`.
- `WooCommerce\ShippingMethodStrategy` - matches WooCommerce shipping method settings page.
- `WooCommerce\ShippingMethodInstanceStrategy` - matches WooCommerce shipping method instance settings page.

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

[](#documentation)

PHPDoc:

###  Health Score

40

—

FairBetter than 86% of packages

Maintenance59

Moderate activity, may be stable

Popularity20

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 75% 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 ~1457 days

Total

2

Last Release

818d ago

PHP version history (2 changes)1.0PHP &gt;=5.6

1.1.0PHP &gt;=7.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/16497f8884c0767d3a114cc1cf8daaa639bac052178b03c59d59dfa95569d50b?d=identicon)[dyszczo](/maintainers/dyszczo)

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

![](https://www.gravatar.com/avatar/97ac8b53a77161e994c106cc2136cf0601d404e5fd4a3295884d692c767636c7?d=identicon)[bjaskulski](/maintainers/bjaskulski)

![](https://avatars.githubusercontent.com/u/75088186?v=4)[Mateusz Dworowy](/maintainers/mdworowy)[@mdworowy](https://github.com/mdworowy)

---

Top Contributors

[![dyszczo](https://avatars.githubusercontent.com/u/1263190?v=4)](https://github.com/dyszczo "dyszczo (3 commits)")[![seostudio](https://avatars.githubusercontent.com/u/8124521?v=4)](https://github.com/seostudio "seostudio (1 commits)")

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/wpdesk-wp-show-decision/health.svg)

```
[![Health](https://phpackages.com/badges/wpdesk-wp-show-decision/health.svg)](https://phpackages.com/packages/wpdesk-wp-show-decision)
```

###  Alternatives

[nystudio107/craft-typogrify

Typogrify prettifies your web typography by preventing ugly quotes and 'widows' and more

70387.5k19](/packages/nystudio107-craft-typogrify)[petercoles/multilingual-language-list

Lookup Objects for Language Names and Codes

41336.8k](/packages/petercoles-multilingual-language-list)[akaunting/laravel-mutable-observer

Mutable observer package for Laravel

11202.6k](/packages/akaunting-laravel-mutable-observer)[cyber-duck/silverstripe-google-tag-manager

Add Tag Manager data layer, events, and ecommerce support for SilverStripe

1628.1k](/packages/cyber-duck-silverstripe-google-tag-manager)[maxtee/blockchain

This is a package designed to integrate with laravel 5.0+

571.2k](/packages/maxtee-blockchain)[epigra/trstringhelper

PHP Türkçe Karakter Destekli String Fonksiyonları (toupper,tolower,ucfirst,ucwords,capitalizefirst) Kütüphanesi

244.1k](/packages/epigra-trstringhelper)

PHPackages © 2026

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