skip to navigation
skip to content

Not Logged In

Flask-Gravatar 0.4.2

Small extension for Flask to make usage of Gravatar service easy.

Package Documentation

About

This is small and simple integration gravatar into flask.

Installation

Flask-Gravatar is on PyPI so all you need is:

pip install Flask-Gravatar

Documentation

Initialize with flask application and default parameters:

gravatar = Gravatar(app,
                    size=100,
                    rating='g',
                    default='retro',
                    force_default=False,
                    use_ssl=False,
                    base_url=None)

Then in your template:

{{ 'zzz.sochi@gmail.com' | gravatar }}

Bigger and adult:

{{ 'zzz.sochi@gmail.com' | gravatar(size=200, rating='x') }}

Parameters

All parameters are described in gravatar documentation.

Testing

Running the test suite is as simple as:

python setup.py test

or, to also show code coverage:

./run-tests.sh
 
File Type Py Version Uploaded on Size
Flask-Gravatar-0.4.2.tar.gz (md5) Source 2015-03-23 13KB
Flask_Gravatar-0.4.2-py2.py3-none-any.whl (md5) Python Wheel 2.7 2015-03-23 5KB
  • Downloads (All Versions):
  • 242 downloads in the last day
  • 1104 downloads in the last week
  • 5451 downloads in the last month