PHPackages                             pedro-mendonca/glotpress-stubs - 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. pedro-mendonca/glotpress-stubs

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

pedro-mendonca/glotpress-stubs
==============================

GlotPress function and class declaration stubs for static analysis.

4.0.3(7mo ago)013.0kMITPHPCI passing

Since Dec 16Pushed 7mo ago1 watchersCompare

[ Source](https://github.com/pedro-mendonca/glotpress-stubs)[ Packagist](https://packagist.org/packages/pedro-mendonca/glotpress-stubs)[ Docs](https://github.com/pedro-mendonca/glotpress-stubs)[ GitHub Sponsors](https://github.com/sponsors/pedro-mendonca)[ RSS](/packages/pedro-mendonca-glotpress-stubs/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (3)Versions (31)Used By (0)

GlotPress Stubs
===============

[](#glotpress-stubs)

GlotPress function and class declaration stubs for static analysis.

[![Packagist version](https://camo.githubusercontent.com/ec4fd8be35f600d323939f50219846b07f0e9275107ddfc2cb96a9dda1b3657b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f706564726f2d6d656e646f6e63612f676c6f7470726573732d73747562733f696e636c7564655f70726572656c6561736573266c6162656c3d5061636b6167697374)](https://packagist.org/packages/pedro-mendonca/glotpress-stubs)[![Packagist stats](https://camo.githubusercontent.com/d35bbcf398f9cda2c5b61cd7894c8269e92023fb0aae24be995fe67472aa800f/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f706564726f2d6d656e646f6e63612f676c6f7470726573732d73747562733f6c6162656c3d446f776e6c6f616473)](https://packagist.org/packages/pedro-mendonca/glotpress-stubs/stats)[![License](https://camo.githubusercontent.com/f493cf37381582525a2887cc64a1aea30358ff6672b1ea43e30ee18a98ca1bec/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f706564726f2d6d656e646f6e63612f676c6f7470726573732d73747562733f6c6162656c3d4c6963656e7365)](https://github.com/pedro-mendonca/glotpress-stubs/blob/main/LICENSE)[![Sponsor](https://camo.githubusercontent.com/35d54e3bc4642d258f0afc03ee3201c7cfbf32cbbdede6c8b287e480b7b969e0/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4769744875622d25463025394625413425384425323053706f6e736f722d6561346161613f6c6f676f3d676974687562)](https://github.com/sponsors/pedro-mendonca)

This package provides stub declarations for [GlotPress](https://glotpress.blog) functions, classes and interfaces.
These stubs can help plugin and theme developers leverage static analysis tools like [PHPStan](https://github.com/phpstan/phpstan), which are unable to parse GlotPress as it is not clean OOP code.

Stubs are generated directly from the [source](https://github.com/GlotPress/GlotPress-WP) using [php-stubs/generator](https://github.com/php-stubs/generator).

### Requirements

[](#requirements)

- PHP ^7.3 or ^8.0

### Installation

[](#installation)

Require this package as a development dependency with [Composer](https://getcomposer.org).

```
composer require --dev pedro-mendonca/glotpress-stubs
```

Alternatively you may download `glotpress-stubs.php` directly.

### Usage in PHPStan

[](#usage-in-phpstan)

Include all stubs in PHPStan configuration file.
You can remove the `# WordPress Stubs` lines if you already use [WordPress extensions for PHPStan](https://github.com/szepeviktor/phpstan-wordpress).

```
parameters:
    scanFiles:
        # WordPress Stubs
        - %rootDir%/../../php-stubs/wordpress-stubs/wordpress-stubs.php
        # GlotPress Stubs
        - %rootDir%/../../pedro-mendonca/glotpress-stubs/glotpress-stubs.php
```

###  Health Score

43

—

FairBetter than 91% of packages

Maintenance65

Regular maintenance activity

Popularity25

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% 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 ~48 days

Recently: every ~148 days

Total

30

Last Release

214d ago

Major Versions

2.3.1 → 3.0.0-alpha.12021-12-16

3.0.0 → 4.0.0-alpha.12022-05-03

### Community

Maintainers

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

---

Top Contributors

[![pedro-mendonca](https://avatars.githubusercontent.com/u/7371591?v=4)](https://github.com/pedro-mendonca "pedro-mendonca (60 commits)")

---

Tags

glotpressphpstanstatic-analysisstubswordpressPHPStanwordpressstatic analysisglotpress

### Embed Badge

![Health badge](/badges/pedro-mendonca-glotpress-stubs/health.svg)

```
[![Health](https://phpackages.com/badges/pedro-mendonca-glotpress-stubs/health.svg)](https://phpackages.com/packages/pedro-mendonca-glotpress-stubs)
```

###  Alternatives

[php-stubs/wordpress-stubs

WordPress function and class declaration stubs for static analysis.

19513.0M263](/packages/php-stubs-wordpress-stubs)[php-stubs/woocommerce-stubs

WooCommerce function and class declaration stubs for static analysis.

942.9M66](/packages/php-stubs-woocommerce-stubs)[php-stubs/wp-cli-stubs

WP-CLI function and class declaration stubs for static analysis.

302.3M79](/packages/php-stubs-wp-cli-stubs)[woocommerce/woocommerce-sniffs

WooCommerce sniffs

496.8M42](/packages/woocommerce-woocommerce-sniffs)[php-stubs/wordpress-globals

Global variables and global constants from WordPress core.

13799.0k17](/packages/php-stubs-wordpress-globals)[johnbillion/wp-compat

PHPStan extension to help verify that your PHP code is compatible with a given version of WordPress

24115.0k10](/packages/johnbillion-wp-compat)

PHPackages © 2026

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