PHPackages                             guzzlefry/twig-age-extension - 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. guzzlefry/twig-age-extension

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

guzzlefry/twig-age-extension
============================

Simple Twig extension to calculate the age in years based on a DateTime instance

217.8k↓100%1PHP

Since Jul 6Pushed 9y ago1 watchersCompare

[ Source](https://github.com/guzzlefry/twig-age-extension)[ Packagist](https://packagist.org/packages/guzzlefry/twig-age-extension)[ RSS](/packages/guzzlefry-twig-age-extension/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

twig-age-extension
==================

[](#twig-age-extension)

Simple Twig extension to calculate the age in years based on a DateTime instance

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

[](#installation)

Install via composer:

```
composer require guzzlefry/twig-age-extension:@dev

```

Add the following to your services.yml file:

```
services:
    twig.extension.date:
        class: Guzzlefry\Twig\AgeExtension
        tags:
            - { name: twig.extension }
```

Usage
-----

[](#usage)

```
{{ user.birthdate | age }}

```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity25

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 60% 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/6664cf295ed2f2589c203b832a4dc311d43f8fc3d6f50ea9df746bfaa0d19d62?d=identicon)[guzzlefry](/maintainers/guzzlefry)

---

Top Contributors

[![TheRealGusBus](https://avatars.githubusercontent.com/u/60719155?v=4)](https://github.com/TheRealGusBus "TheRealGusBus (3 commits)")[![guzzlefry](https://avatars.githubusercontent.com/u/3201334?v=4)](https://github.com/guzzlefry "guzzlefry (2 commits)")

### Embed Badge

![Health badge](/badges/guzzlefry-twig-age-extension/health.svg)

```
[![Health](https://phpackages.com/badges/guzzlefry-twig-age-extension/health.svg)](https://phpackages.com/packages/guzzlefry-twig-age-extension)
```

###  Alternatives

[happy-types/enumerable-type

Strongly typed implementation of enumerable type in PHP which helps us to write a safer more readable code.

4742.6k](/packages/happy-types-enumerable-type)

PHPackages © 2026

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