PHPackages                             techwilk/twig-hashtagify - 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. [Templating &amp; Views](/categories/templating)
4. /
5. techwilk/twig-hashtagify

ActiveLibrary[Templating &amp; Views](/categories/templating)

techwilk/twig-hashtagify
========================

TWIG filter to turn hashtags into html links.

v3.0.1(1y ago)01.6kMITPHPPHP &gt;=7.4

Since May 30Pushed 1y ago1 watchersCompare

[ Source](https://github.com/TechWilk/twig-hashtagify)[ Packagist](https://packagist.org/packages/techwilk/twig-hashtagify)[ Docs](https://github.com/TechWilk/TWIG-Hashtagify)[ RSS](/packages/techwilk-twig-hashtagify/feed)WikiDiscussions master Synced 4w ago

READMEChangelog (7)Dependencies (3)Versions (13)Used By (0)

Hashtagify (filter for TWIG)
============================

[](#hashtagify-filter-for-twig)

[![Total Downloads](https://camo.githubusercontent.com/bf99fc2222dcf3ea9dd58a780e7a8588ceb4ad4ae6da2b6209a5705411b2ee21/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7465636877696c6b2f747769672d686173687461676966792e737667)](https://packagist.org/packages/techwilk/twig-hashtagify)[![Latest Stable Version](https://camo.githubusercontent.com/e9275bb9e6dd71a381a96003d8f945325baf81d33f44aa2d77ce8290b4734986/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7465636877696c6b2f747769672d686173687461676966792e737667)](https://packagist.org/packages/techwilk/twig-hashtagify)[![License](https://camo.githubusercontent.com/a3c7b7f3941def86bfe5ad1f251ab1446d5bff3b8d1679b3a15d83e58943bbe8/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f7465636877696c6b2f747769672d686173687461676966792e737667)](https://packagist.org/packages/techwilk/twig-hashtagify)

TWIG filter to turn hashtags into html links. Provides interfaces to work with a Slim Framework Router, or a base URL.

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

[](#installation)

1. Install through composer.

```
composer require techwilk/twig-hashtagify

```

2. Then configure base url using one of the interfaces provided, or write your own:

### Base Url Interface:

[](#base-url-interface)

```
use TechWilk\TwigHashtagify\HashtagifyUrlGenerator\BaseUrlHashtagifyUrlGenerator;
use TechWilk\TwigHashtagify\HashtagifyExtension;
use TechWilk\TwigHashtagify\HashtagifyRuntimeLoader;

$urlGenerator = new BaseUrlHashtagifyUrlGenerator('https://example.com/hashtag/');
$twig->addExtension(new HashtagifyExtension());
$twig->addRuntimeLoader(new HashtagifyRuntimeLoader($urlGenerator));
```

### Slim Router Interface:

[](#slim-router-interface)

Add the following extension as a twig dependency

```
use TechWilk\TwigHashtagify\HashtagifyExtension;

$twig->addExtension(new HashtagifyExtension());
```

Add the following middleware after your `TwigMiddleware` to setup our dependencies

```
use TechWilk\TwigHashtagify\HashtagifyMiddleware;

$app->add(HashtagifyMiddleware::createFromContainer($app, 'route-name', 'argument-name'));
```

Use
---

[](#use)

Use as a standard twig filter:

```
{{ 'this text with #hashtags' | hashtagify }}
```

Example
-------

[](#example)

Turns this:

```
This is some text with #hashtags in it
```

Into this:

```
This is some text with #hashtags in it
```

###  Health Score

36

—

LowBetter than 79% of packages

Maintenance34

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity70

Established project with proven stability

 Bus Factor1

Top contributor holds 89.7% 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 ~443 days

Recently: every ~219 days

Total

7

Last Release

657d ago

Major Versions

v1.0.2 → v2.0.02022-04-19

v2.0.1 → v3.0.02023-03-08

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/9367803?v=4)[Christopher Wilkinson](/maintainers/TechWilk)[@TechWilk](https://github.com/TechWilk)

---

Top Contributors

[![TechWilk](https://avatars.githubusercontent.com/u/9367803?v=4)](https://github.com/TechWilk "TechWilk (52 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (3 commits)")[![StyleCIBot](https://avatars.githubusercontent.com/u/11048387?v=4)](https://github.com/StyleCIBot "StyleCIBot (3 commits)")

---

Tags

twigslimfilterextensionhashtag

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/techwilk-twig-hashtagify/health.svg)

```
[![Health](https://phpackages.com/badges/techwilk-twig-hashtagify/health.svg)](https://phpackages.com/packages/techwilk-twig-hashtagify)
```

###  Alternatives

[symfony/ux-twig-component

Twig components for Symfony

22017.2M313](/packages/symfony-ux-twig-component)[symfony/ux-live-component

Live components for Symfony

1636.5M115](/packages/symfony-ux-live-component)[tales-from-a-dev/twig-tailwind-extra

A Twig extension for Tailwind

36982.8k12](/packages/tales-from-a-dev-twig-tailwind-extra)[symfony/ux-toolkit

A tool to easily create a design system in your Symfony app with customizable, well-crafted Twig components

1682.8k1](/packages/symfony-ux-toolkit)[umanit/twig-image-extension

An extension to facilitate the integration of responsive images' markup in Twig templates.

1043.8k](/packages/umanit-twig-image-extension)[mati365/ckeditor5-symfony

CKEditor 5 integration for Symfony

261.9k](/packages/mati365-ckeditor5-symfony)

PHPackages © 2026

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