PHPackages                             jmf/type-validation - 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. [Validation &amp; Sanitization](/categories/validation)
4. /
5. jmf/type-validation

ActiveLibrary[Validation &amp; Sanitization](/categories/validation)

jmf/type-validation
===================

Allows to check if a variable is of the expected type, using a type specification string like the ones in PHPDoc blocks (int, \\Foo\\Bar\[\], null|string, etc).

4.0.0(2y ago)010MITPHP &gt;=8.2

Since Apr 4Compare

[ Source](https://github.com/jmfeurprier/type-validation)[ Packagist](https://packagist.org/packages/jmf/type-validation)[ RSS](/packages/jmf-type-validation/feed)WikiDiscussions Synced 1mo ago

READMEChangelogDependencies (7)Versions (13)Used By (0)

### README not available

The README for this package hasn't been synced yet. View it on [GitHub](https://github.com/jmfeurprier/type-validation).

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community2

Small or concentrated contributor base

Maturity83

Battle-tested with a long release history

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

Recently: every ~263 days

Total

13

Last Release

1049d ago

Major Versions

1.0.x-dev → 2.0.02015-05-12

2.0.x-dev → 3.0.02020-07-03

3.1.x-dev → 4.0.02023-07-01

PHP version history (3 changes)1.0.0PHP &gt;=5.3.3

3.0.0PHP &gt;=7.4

4.0.0PHP &gt;=8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/6b08b8105ec8bc88d1c911e10dbf156814769650a67960e2f3d71ed6d2417f0d?d=identicon)[jmfeurprier](/maintainers/jmfeurprier)

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan, Rector

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/jmf-type-validation/health.svg)

```
[![Health](https://phpackages.com/badges/jmf-type-validation/health.svg)](https://phpackages.com/packages/jmf-type-validation)
```

###  Alternatives

[webmozart/assert

Assertions to validate method input/output with nice error messages.

7.6k894.0M1.2k](/packages/webmozart-assert)[bensampo/laravel-enum

Simple, extensible and powerful enumeration implementation for Laravel.

2.0k15.9M104](/packages/bensampo-laravel-enum)[swaggest/json-schema

High definition PHP structures with JSON-schema based validation

48612.5M73](/packages/swaggest-json-schema)[stevebauman/purify

An HTML Purifier / Sanitizer for Laravel

5325.6M19](/packages/stevebauman-purify)[ashallendesign/laravel-config-validator

A package for validating your Laravel app's config.

217905.3k5](/packages/ashallendesign-laravel-config-validator)[crazybooot/base64-validation

Laravel validators for base64 encoded files

1341.9M8](/packages/crazybooot-base64-validation)

PHPackages © 2026

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