Django SVG templatetag¶
Inject a SVG file into your Django template.
Documentation¶
The full documentation is at https://django-svg-templatetag.readthedocs.org.
Quickstart¶
Install Django SVG templatetag:
pip install django-svg-templatetag
Then use it in a project:
{% load svg %}
{% svg path [as varname] %}
Examples:
{% svg "myapp/icons/icon.svg" %}
{% svg variable_with_path %}
{% svg "myapp/icons/icon.svg" as icon_svg_content %}
{% svg variable_with_path as varname %}
Features¶
- TODO
Running Tests¶
Does the code actually work?
source <YOURVIRTUALENV>/bin/activate
(myenv) $ pip install -r requirements_test.txt
(myenv) $ python runtests.py