PHPackages                             gravatarphp/twig-integration - 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. gravatarphp/twig-integration

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

gravatarphp/twig-integration
============================

Integrates Gravatar into Twig templating engine

v2.0.0(5y ago)35761MITPHPPHP &gt;=7.2CI failing

Since Jun 25Pushed 5y ago2 watchersCompare

[ Source](https://github.com/gravatarphp/twig-integration)[ Packagist](https://packagist.org/packages/gravatarphp/twig-integration)[ Docs](http://gravatarphp.com)[ GitHub Sponsors](https://github.com/gmponos)[ GitHub Sponsors](https://github.com/sagikazarmark)[ RSS](/packages/gravatarphp-twig-integration/feed)WikiDiscussions master Synced yesterday

READMEChangelog (2)Dependencies (3)Versions (3)Used By (0)

Gravatar Twig Integration
=========================

[](#gravatar-twig-integration)

[![Latest Version](https://camo.githubusercontent.com/ee734740d9b648ba2e9bc73cb243c1496e3f690249b73a585ecb2c49bf888ddc/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f67726176617461727068702f747769672d696e746567726174696f6e2e7376673f7374796c653d666c61742d737175617265)](https://github.com/gravatarphp/twig-integration/releases)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE)[![Build Status](https://camo.githubusercontent.com/132025b1ff91caad213c4cccbb2813d65e7eaf28fd74c8a791701f460935f301/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f67726176617461727068702f747769672d696e746567726174696f6e2e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.com/gravatarphp/twig-integration)[![Total Downloads](https://camo.githubusercontent.com/db7a7185dd3488c1973353048eb84a164f3015a1e097a55274b13439b3c149f5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f67726176617461727068702f747769672d696e746567726174696f6e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gravatarphp/twig-integration)

**Integrates Gravatar into Twig templating engine.**

Install
-------

[](#install)

Via Composer

```
$ composer require gravatarphp/twig-integration
```

Usage
-----

[](#usage)

```
use Gravatar\Gravatar;
use Gravatar\Twig\GravatarExtension;

$extension = new GravatarExtension(new Gravatar());

$environment->addExtension($extension);
```

Use it in a twig template:

```
Avatar
Profile
vCard
QR Code
```

Options can be provided as first filter parameter, for example:

```
Avatar
```

All options can be found on [Gravatar's documentation](http://gravatar.com/site/implement/images/).

Testing
-------

[](#testing)

```
$ composer test
```

Credits
-------

[](#credits)

- [Márk Sági-Kazár](https://github.com/sagikazarmark)
- [George Mponos](https://github.com/gmponos)
- [All Contributors](https://github.com/gravatarphp/twig-integration/contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE) for more information.

###  Health Score

31

—

LowBetter than 66% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity22

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 88.2% 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 ~1491 days

Total

2

Last Release

2169d ago

Major Versions

v1.0.0 → v2.0.02020-07-25

PHP version history (2 changes)v1.0.0PHP &gt;=5.4

v2.0.0PHP &gt;=7.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/0e4e105cea62b616d4cb376b08a849b6a428f646998537de150d16a8eb537b90?d=identicon)[mark.sagikazar](/maintainers/mark.sagikazar)

![](https://avatars.githubusercontent.com/u/5675248?v=4)[Mponos George](/maintainers/gmponos)[@gmponos](https://github.com/gmponos)

---

Top Contributors

[![sagikazarmark](https://avatars.githubusercontent.com/u/1226384?v=4)](https://github.com/sagikazarmark "sagikazarmark (15 commits)")[![gmponos](https://avatars.githubusercontent.com/u/5675248?v=4)](https://github.com/gmponos "gmponos (1 commits)")[![mnapoli](https://avatars.githubusercontent.com/u/720328?v=4)](https://github.com/mnapoli "mnapoli (1 commits)")

---

Tags

twiggravatar

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/gravatarphp-twig-integration/health.svg)

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

###  Alternatives

[symfony/ux-twig-component

Twig components for Symfony

22018.6M356](/packages/symfony-ux-twig-component)[symfony/ux-live-component

Live components for Symfony

1647.0M128](/packages/symfony-ux-live-component)[symfony/ux-toolkit

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

16126.1k1](/packages/symfony-ux-toolkit)[mati365/ckeditor5-symfony

CKEditor 5 integration for Symfony

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

PHPackages © 2026

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