Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alexeevdv/twig-gravatar-filter
Twig filter that converts email to Gravatar image url.
https://github.com/alexeevdv/twig-gravatar-filter
Last synced: about 1 month ago
JSON representation
Twig filter that converts email to Gravatar image url.
- Host: GitHub
- URL: https://github.com/alexeevdv/twig-gravatar-filter
- Owner: alexeevdv
- License: mit
- Created: 2018-12-04T13:22:15.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2018-12-04T16:09:31.000Z (about 6 years ago)
- Last Synced: 2024-11-22T16:30:11.973Z (about 2 months ago)
- Language: PHP
- Homepage:
- Size: 5.86 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Twig Gravatar filter
[![Build Status](https://travis-ci.org/alexeevdv/twig-gravatar-filter.svg?branch=master)](https://travis-ci.org/alexeevdv/twig-gravatar-filter)
[![codecov](https://codecov.io/gh/alexeevdv/twig-gravatar-filter/branch/master/graph/badge.svg)](https://codecov.io/gh/alexeevdv/twig-gravatar-filter)
![PHP 5.6](https://img.shields.io/badge/PHP-5.6-green.svg)
![PHP 7.0](https://img.shields.io/badge/PHP-7.0-green.svg)
![PHP 7.1](https://img.shields.io/badge/PHP-7.1-green.svg)
![PHP 7.2](https://img.shields.io/badge/PHP-7.2-green.svg)This is Twig filter which converts email to Gravatar image url.
## Installation
The preferred way to install this extension is through [composer](https://getcomposer.org/download/).
Either run
```bash
$ composer require alexeevdv/twig-gravatar-filter "^1.0"
```or add
```
"alexeevdv/twig-gravatar-filter": "^1.0"
```to the ```require``` section of your `composer.json` file.
## Configuration
### Symfony
```
twig.extension.gravatar:
class: \alexeevdv\twig\GravatarFilter
tags:
- { name: twig.extension }
```### Standalone
```php
$twig->addExtension(new \alexeevdv\twig\GravatarFilter);
```## Usage
### Without parameters
```html
```### With different parameters
```html
```## Parameters
For possible values please refer to [Gravatar documentation](https://en.gravatar.com/site/implement/images/)