PHPackages                             dmwg/wisski\_entity\_reference\_tree - 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. dmwg/wisski\_entity\_reference\_tree

ActiveDrupal-module[Utility &amp; Helpers](/categories/utility)

dmwg/wisski\_entity\_reference\_tree
====================================

An entity reference tree builder for WissKI.

1.0.0(1y ago)0154[4 PRs](https://github.com/dmwg/wisski_entity_reference_tree/pulls)GPL-3.0-or-laterPHPPHP &gt;=8.2CI passing

Since May 14Pushed 1y ago1 watchersCompare

[ Source](https://github.com/dmwg/wisski_entity_reference_tree)[ Packagist](https://packagist.org/packages/dmwg/wisski_entity_reference_tree)[ Docs](https://github.com/dmwg/wisski_entity_reference_tree)[ RSS](/packages/dmwg-wisski-entity-reference-tree/feed)WikiDiscussions main Synced 1mo ago

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

WissKI entity reference tree 🌳️
===============================

[](#wisski-entity-reference-tree-️)

[![CI workflow](https://github.com/dmwg/wisski_entity_reference_tree/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/dmwg/wisski_entity_reference_tree/actions/workflows/ci.yml/badge.svg?branch=main) [![Packagist Version](https://camo.githubusercontent.com/d5e69f07543ab6e5e7bd2f9eb0fb818717fbab3ab7a56fd6ff9e8071ad65bf0a/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f646d77672f776973736b695f656e746974795f7265666572656e63655f74726565)](https://packagist.org/packages/dmwg/wisski_entity_reference_tree) [![Packagist Downloads](https://camo.githubusercontent.com/078e43045d3ba2d6e8b7a6fe00c166c24fd429a457c44ff41e6edb32b439c7fe/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f646d77672f776973736b695f656e746974795f7265666572656e63655f74726565)](https://packagist.org/packages/dmwg/wisski_entity_reference_tree) [![GitHub License](https://camo.githubusercontent.com/934e000a5082870f3bdd15b999b371277127162271f3752c9f054bd7fb69d9d4/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f646d77672f776973736b695f656e746974795f7265666572656e63655f74726565)](https://packagist.org/packages/dmwg/wisski_entity_reference_tree) [![Packagist Dependency Version](https://camo.githubusercontent.com/a49531a3da591507c906b0570b2e5c07596afb3853d1881173e8d5542e70e60d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646570656e64656e63792d762f646d77672f776973736b695f656e746974795f7265666572656e63655f747265652f706870)](https://packagist.org/packages/dmwg/wisski_entity_reference_tree)

A Drupal module extending [drupal/entity\_reference\_tree](https://www.drupal.org/project/entity_reference_tree) to provide a hierarchy of entities configured through disambiguation points in the pathbuilder, e.g., tags or other forms of taxonomy. This module depends on `drupal/entity_reference_tree` and was tested successfully with `2.1.0`.

**Note:** This module depends on the dynamic dispatch to other tree-builders defined in `src/web/modules/contrib/entity_reference_tree/src/Controller/EntityReferenceTreeController.php:104`. Should this dispatch ever go away, this module **will break** (or at least cease to function, which is the same).

Required dynamic dispatch in `drupal/entity_reference_tree`:

```
// Instance a entity tree builder for this entity type if it exists.
if (\Drupal::hasService('entity_reference_' . $entity_type . '_tree_builder')) {
  $treeBuilder = \Drupal::service('entity_reference_' . $entity_type . '_tree_builder');
}
```

[![](./screenshot.png "A screenshot of the reference tree widget")](./screenshot.png)

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

[](#requirements)

- PHP `^8.2`
- `drupal/wisski` (tested on `3.15`)[1](#user-content-fn-1-4f6edc880da8c829dd5fb60f50766fbc)
- `drupal/entity_reference_tree` (tested on `2.3.2`)[1](#user-content-fn-1-4f6edc880da8c829dd5fb60f50766fbc)

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

[](#installation)

```
$ composer require dmwg/wisski_entity_reference_tree
```

Usage
-----

[](#usage)

1. Enable this module, along with `drupal/entity_reference_tree` via `/admin/modules`
2. Under `/admin/structure/`, configure the required bundle:
    1. Go to `Manage form display`
    2. For the required field, set the type to "Entity reference tree"
    3. (optional) Configure the theme of the widget and other layout properties

Contributing
------------

[](#contributing)

We welcome all and any contributions via Pull Requests to this repository!

### Local development environment

[](#local-development-environment)

For local development, it is **highly recommended** to install this module into an existing Drupal codebase, e.g., under `web/modules/custom`. Furthermore, we recommend at least a basic WissKI installation (c.f. [`drupal/wisski`](https://www.drupal.org/project/wisski)). This will provide a richer code-completion for base-Drupal, as well as WissKI-specific code.

**Important:** without a local Drupal installation, static analysis via `phpstan` will fail miserably, as it relies on a Drupal autoloader.

The following example assumes an installation, and clones into `web/modules/custom`:

```
$ cd /web/modules/custom
$ git clone https://github.com/dmwg/wisski_entity_reference_tree
$ cd wisski_entity_reference
$ composer install
```

### Linting &amp; Static analysis

[](#linting--static-analysis)

Please run `vendor/bin/phpcs --standard=Drupal` and fix any flagged errors; `vendor/bin/phpcbf --standard=Drupal src` can assist.

Please run `vendor/bin/phpstan` and fix any errors; don't let a failing build discourage you, we'll try and figure it out in the PR.

Authors and acknowledgment
--------------------------

[](#authors-and-acknowledgment)

- `Oliver Baumann `
    - Refactoring &amp; Maintenance
- `Myriel Fichtner`
    - Concept &amp; original version
- `Philipp Eisenhuth`
    - Concept &amp; original version

Project status
--------------

[](#project-status)

Alive, but dormant.

Footnotes
---------

1. Older versions might work fine. [↩](#user-content-fnref-1-4f6edc880da8c829dd5fb60f50766fbc) [↩2](#user-content-fnref-1-2-4f6edc880da8c829dd5fb60f50766fbc)

###  Health Score

32

—

LowBetter than 71% of packages

Maintenance42

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 60.4% 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 ~181 days

Total

2

Last Release

544d ago

Major Versions

0.1.0 → 1.0.02024-11-11

### Community

Maintainers

![](https://www.gravatar.com/avatar/9c41910c650f05b98fff6b8c345bfc8b3b04d2df4631f46d8203620039893248?d=identicon)[baumanno](/maintainers/baumanno)

---

Top Contributors

[![baumanno](https://avatars.githubusercontent.com/u/1183339?v=4)](https://github.com/baumanno "baumanno (29 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (19 commits)")

###  Code Quality

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/dmwg-wisski-entity-reference-tree/health.svg)

```
[![Health](https://phpackages.com/badges/dmwg-wisski-entity-reference-tree/health.svg)](https://phpackages.com/packages/dmwg-wisski-entity-reference-tree)
```

###  Alternatives

[cybercog/laravel-paket

Composer personal web interface. Manage Laravel dependencies without switching to command line!

1753.3k](/packages/cybercog-laravel-paket)[laravel-frontend-presets/inertiajs

A Laravel frontend preset to get you up and running with Inertia.js

1464.5k](/packages/laravel-frontend-presets-inertiajs)[dominicwatts/faker

Console based fake data generator - just generate what you need

413.5k](/packages/dominicwatts-faker)[markwalet/laravel-packagist

A Laravel wrapper for the `spatie/packagist-api` package.

132.1k](/packages/markwalet-laravel-packagist)

PHPackages © 2026

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