PHPackages                             darkfriend/php7-type - 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. darkfriend/php7-type

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

darkfriend/php7-type
====================

PHP7-helper for type data

1.0.0(6y ago)0311PHPPHP &gt;=7.0

Since Dec 21Pushed 6y ago1 watchersCompare

[ Source](https://github.com/darkfriend/php7-type)[ Packagist](https://packagist.org/packages/darkfriend/php7-type)[ Docs](https://github.com/darkfriend/php7-helpers)[ RSS](/packages/darkfriend-php7-type/feed)WikiDiscussions master Synced 6d ago

READMEChangelog (1)DependenciesVersions (2)Used By (1)

TypeHelper
==========

[](#typehelper)

`composer require darkfriend/php7-type`

- `TypeHelper::toStrictType($value)` - return $value to strict type

Example
-------

[](#example)

```
use \darkfriend\helpers\TypeHelper;

var_dump(
    TypeHelper::toStrict('false'), // bool(false)
    TypeHelper::toStrict(null), // NULL
    TypeHelper::toStrict(0), // int(0)
    TypeHelper::toStrict('0'), // int(0)
    TypeHelper::toStrict('1'), // int(1)
    TypeHelper::toStrict(1), // int(1)
    TypeHelper::toStrict('1.1'), // float(1.1)
    TypeHelper::toStrict(1.1), // float(1.1)
    TypeHelper::toStrict(true), // bool(true)
    TypeHelper::toStrict(false), // bool(false)
    TypeHelper::toStrict('my string'), // string(9) "my string"
    TypeHelper::toStrict('') // string(0) ""
);
```

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 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

Unknown

Total

1

Last Release

2340d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/302f1cdc7cb85fc89550bad0c164e195b831f50de8a2a148fa754670d5f328cc?d=identicon)[darkfriend](/maintainers/darkfriend)

---

Top Contributors

[![darkfriend](https://avatars.githubusercontent.com/u/7825114?v=4)](https://github.com/darkfriend "darkfriend (2 commits)")

---

Tags

helperphpphp7strict-typetype-helperphpdevdevelopmentPHP7typesdarkfriend

### Embed Badge

![Health badge](/badges/darkfriend-php7-type/health.svg)

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

PHPackages © 2026

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