Commit 261a4567 by Timothée Peignier

Move the jinja2 extension and templates.

parent f292098e
......@@ -87,7 +87,7 @@ Jinja
=====
Pipeline also includes Jinja2 support and is used almost identically to the Django Template tags implementation.
You just need to pass ``pipeline.jinja2.ext.PipelineExtension`` to your Jinja2 environment.
You just need to pass ``pipeline.templatetags.ext.PipelineExtension`` to your Jinja2 environment.
Templates
---------
......
<link href="{{ url }}" rel="stylesheet" type="{{ type }}"{% if media %} media="{{ media }}"{% endif %}{% if charset %} charset="{{ charset }}"{% endif %} />
<script{% if async %} async{% endif %}{% if defer %} defer{% endif %} type="text/javascript">
{{ source|safe }}
</script>
<script{% if async %} async{% endif %}{% if defer %} defer{% endif %} type="{{ type }}" src="{{ url }}" charset="utf-8"></script>
......@@ -5,9 +5,9 @@ from jinja2.ext import Extension
from django.contrib.staticfiles.storage import staticfiles_storage
from pipeline.packager import PackageNotFound
from pipeline.utils import guess_type
from pipeline.templatetags.pipeline import PipelineMixin
from ..packager import PackageNotFound
from ..utils import guess_type
from .pipeline import PipelineMixin
class PipelineExtension(PipelineMixin, Extension):
......
......@@ -6,7 +6,7 @@ from jinja2 import Environment, PackageLoader
from django.template import Template, Context
from django.test import TestCase
from pipeline.jinja2.ext import PipelineExtension
from pipeline.templatetags.ext import PipelineExtension
from tests.utils import pipeline_settings
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment