PHPackages                             uco/twig-extensions-bundle - 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. uco/twig-extensions-bundle

AbandonedArchivedSymfony-bundle[Templating &amp; Views](/categories/templating)

uco/twig-extensions-bundle
==========================

Twig Extensions

52813[1 issues](https://github.com/sgomez/UcoTwigExtensionsBundle/issues)PHP

Since Jul 28Pushed 13y agoCompare

[ Source](https://github.com/sgomez/UcoTwigExtensionsBundle)[ Packagist](https://packagist.org/packages/uco/twig-extensions-bundle)[ RSS](/packages/uco-twig-extensions-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

The UcoTwigExtensions
=====================

[](#the-ucotwigextensions)

This bundle provides the following filters:

- `dateage`: The date filter is able to format the age of a date::

    The post was sent {{ post.published\_at | dateage }} ago.

    {# Returns 'The post was sent 5 days and 1 hour ago.' #}

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

[](#installation)

You need to install de submodule on the deps file::

```
// deps
[UcoTwigExtensionsBundle]
    git=git://github.com/sgomez/UcoTwigExtensionsBundle.git
    target=/bundles/Uco/TwigExtensionsBundle

```

And then::

```
bash$ php bin/vendors install

```

Configuration
-------------

[](#configuration)

Add this to app/autoload.php::

```
// app/autoload.php
$loader->registerNamespaces(array(
  // ...
  'Uco'              => __DIR__.'/../vendor/bundles',
  // ...
));

```

And this to app/AppKernel.php::

```
// app/AppKernel.php
$bundles = array(
  // ...
  new Uco\TwigExtensionsBundle\UcoTwigExtensionsBundle(),
  // ...
);

```

This filter uses the traslator service so, you need to activate it::

```
// app/config/config.yml
framework:
    translator:      { fallback: en }

```

Usage
-----

[](#usage)

How to use::

- Filter `dateage`

    {{ \[datetime instance or string\] | dateage }}

You can also specify the timezone, the message catalog and the locale for translations::

```
{{ [datetime instance or string] | dateage( *timezone*, *catalog*, *locale*) }}
{{ [datetime instance or string] | dateage("Europe/Madrid", "admin")  }}

```

By default, the message catalog is "TwigExtensionsDate".

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance16

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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/a8a6bc378d1f2a9189b00012568a661211128721da2695337e714b1048cafb43?d=identicon)[Briareos](/maintainers/Briareos)

---

Top Contributors

[![sgomez](https://avatars.githubusercontent.com/u/580701?v=4)](https://github.com/sgomez "sgomez (5 commits)")[![chrisixion](https://avatars.githubusercontent.com/u/1121888?v=4)](https://github.com/chrisixion "chrisixion (4 commits)")[![mazen](https://avatars.githubusercontent.com/u/118904?v=4)](https://github.com/mazen "mazen (3 commits)")

### Embed Badge

![Health badge](/badges/uco-twig-extensions-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/uco-twig-extensions-bundle/health.svg)](https://phpackages.com/packages/uco-twig-extensions-bundle)
```

###  Alternatives

[mustache/mustache

A Mustache implementation in PHP.

3.3k44.6M291](/packages/mustache-mustache)[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9682.1M97](/packages/roots-acorn)[whitecube/nova-flexible-content

Flexible Content &amp; Repeater Fields for Laravel Nova.

8053.0M25](/packages/whitecube-nova-flexible-content)[mopa/bootstrap-bundle

Easy integration of twitters bootstrap into symfony2

7042.9M33](/packages/mopa-bootstrap-bundle)[limenius/react-bundle

Client and Server-side react rendering in a Symfony Bundle

3871.2M](/packages/limenius-react-bundle)[symfony/ux-icons

Renders local and remote SVG icons in your Twig templates.

545.8M69](/packages/symfony-ux-icons)

PHPackages © 2026

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