Fix modern django compatibility.

This commit is contained in:
Emil Stenström 2019-11-23 18:27:13 +01:00
parent d280fa84a8
commit 458b5383e0
3 changed files with 7 additions and 3 deletions

View file

@ -2,8 +2,11 @@ sudo: false
language: python
python:
- "2.7"
- "3.3"
- "3.4"
- "3.5"
- "3.6"
- "3.7"
- "3.8"
install: pip install tox-travis
script: tox
branches:

View file

@ -1,5 +1,6 @@
from django import template
from django_components.component import registry
from django.utils.safestring import mark_safe
register = template.Library()
@ -11,7 +12,7 @@ def component_dependencies_tag():
for component_class in unique_component_classes:
out.append(component_class.render_dependencies())
return "\n".join(out)
return mark_safe("\n".join(out))
@register.simple_tag(name="component")
def component_tag(name, *args, **kwargs):

View file

@ -7,7 +7,7 @@ envlist = py27-django111,py34-django{111,20},py{35,36,37,38}-django{111,20,21,22
3.5 = py35-django{111,20,21,22}
3.6 = py36-django{111,20,21,22}
3.7 = py37-django{111,20,21,22}
3.8 = py37-django{111,20,21,22}
3.8 = py38-django{111,20,21,22}
[testenv]
deps =