using django filters in jinja2

django, django-templates, google-app-engine, jinja2, python

Solution

The `timesince` function that the Django filter uses can be found here: https://github.com/django/django/blob/master/django/utils/timesince.py

Documentation on writing custom jinja filters can be found here: http://jinja.pocoo.org/docs/api/#custom-filters

Problem

I am developing an application on appengine, and want to use the awesome `timesince` django templatetag. Since I am using jinja2, I do not have the timesince filter available. How can I import it from django and use in jinja template. I saw this question, but it does not serve the need.

Original source