PHPackages                             navarr/hugger - 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. [PSR &amp; Standards](/categories/psr-standards)
4. /
5. navarr/hugger

ActiveLibrary[PSR &amp; Standards](/categories/psr-standards)

navarr/hugger
=============

PSR-8 Implementation

00PHP

Since Nov 30Pushed 4y ago1 watchersCompare

[ Source](https://github.com/navarr/hugger)[ Packagist](https://packagist.org/packages/navarr/hugger)[ RSS](/packages/navarr-hugger/feed)WikiDiscussions main Synced 5d ago

READMEChangelogDependenciesVersions (1)Used By (0)

Hugger (PSR-8)
==============

[](#hugger-psr-8)

[![Latest Stable Version](https://camo.githubusercontent.com/c464bce7ae8c76678111e1239b2ffeb48f62688cad419506b16e986578e78636/687474703a2f2f706f7365722e707567782e6f72672f6e61766172722f6875676765722f76)](https://packagist.org/packages/navarr/hugger)[![Total Downloads](https://camo.githubusercontent.com/e515cb687940b22651735a02540ac27e3a540e9d46d577c53239df2f7f54a96c/687474703a2f2f706f7365722e707567782e6f72672f6e61766172722f6875676765722f646f776e6c6f616473)](https://packagist.org/packages/navarr/hugger)[![Latest Unstable Version](https://camo.githubusercontent.com/75f83dc17946201f21625748554a9def9e30b94b6c79b39a2bb022080acda814/687474703a2f2f706f7365722e707567782e6f72672f6e61766172722f6875676765722f762f756e737461626c65)](https://packagist.org/packages/navarr/hugger)[![License](https://camo.githubusercontent.com/cc0053b34c91cd81e15960c8947e4050fd0588eebcb0ceb43f12524f2cdc94ef/687474703a2f2f706f7365722e707567782e6f72672f6e61766172722f6875676765722f6c6963656e7365)](https://packagist.org/packages/navarr/hugger)
[![Tests](https://github.com/navarr/hugger/actions/workflows/commit.yml/badge.svg)](https://github.com/navarr/hugger/actions/workflows/commit.yml/badge.svg)[![Code Coverage](https://camo.githubusercontent.com/f8c5d74a9b040044560597d736e0add45aab705fec96add5676b23f2e9e1e675/68747470733a2f2f636f6465636f762e696f2f67682f6e61766172722f6875676765722f6272616e63682f6d61696e2f67726170682f62616467652e7376673f746f6b656e3d4248544b4f5a5a445233)](https://camo.githubusercontent.com/f8c5d74a9b040044560597d736e0add45aab705fec96add5676b23f2e9e1e675/68747470733a2f2f636f6465636f762e696f2f67682f6e61766172722f6875676765722f6272616e63682f6d61696e2f67726170682f62616467652e7376673f746f6b656e3d4248544b4f5a5a445233)

This is an implementation of PSR-8. This package includes a Hugger class (which is always happy to hug), as well as a GroupHuggableTrait, so you can add hugging functionality to any class.

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

[](#installation)

Until such time as PSR-8 is un-abandoned, you need to install both my own implementation of its interfaces, as well as this hugging library.

```
composer require navarr/psr-hug-interfaces:@dev navarr/hugger:@dev

```

Usage
-----

[](#usage)

```
class ClassThatWantsToHug
{
    use \Navarr\Hugger\GroupHuggableTrait;
}

$hugger = new ClassThatWantsToHug();
$otherHugger = new \Navarr\Hugger\Hugger();

$hugger->hug($otherHugger);
// Hugger will call $otherHugger->hug($other)

$hugger->groupHug([$otherHugger]);
```

###  Health Score

14

—

LowBetter than 2% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity0

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity28

Early-stage or recently created project

 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/24959115e049fb1d71612462e9106b345b3e0e6126439493514018cd440e8937?d=identicon)[navarr](/maintainers/navarr)

---

Top Contributors

[![navarr](https://avatars.githubusercontent.com/u/145128?v=4)](https://github.com/navarr "navarr (6 commits)")

### Embed Badge

![Health badge](/badges/navarr-hugger/health.svg)

```
[![Health](https://phpackages.com/badges/navarr-hugger/health.svg)](https://phpackages.com/packages/navarr-hugger)
```

###  Alternatives

[phpdocumentor/type-resolver

A PSR-5 based resolver of Class names, Types and Structural Element Names

9.2k719.5M166](/packages/phpdocumentor-type-resolver)[pimple/pimple

Pimple, a simple Dependency Injection Container

2.7k130.5M1.4k](/packages/pimple-pimple)[league/container

A fast and intuitive dependency injection container.

86387.8M343](/packages/league-container)[stella-maris/clock

A pre-release of the proposed PSR-20 Clock-Interface

7947.5M2](/packages/stella-maris-clock)[wptrt/wpthemereview

PHP\_CodeSniffer rules (sniffs) to verify theme compliance with the rules for theme hosting on wordpress.org

217736.5k29](/packages/wptrt-wpthemereview)[inpsyde/modularity

Modular PSR-11 implementation for WordPress plugins, themes or libraries.

54383.3k3](/packages/inpsyde-modularity)

PHPackages © 2026

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