A Django template tag for easy use of SVG sprites in templates.
https://tmb.codeberg.page/django-svg-sprite/
- Python 74.5%
- HTML 21.1%
- Shell 4.4%
|
All checks were successful
Update Docs / docs (push) Successful in 37s
Reviewed-on: #23 Co-authored-by: Tobias Bölz <tobias@boelz.eu> Co-committed-by: Tobias Bölz <tobias@boelz.eu> |
||
|---|---|---|
| .forgejo/workflows | ||
| .githooks | ||
| django_svg_sprite | ||
| docs | ||
| example | ||
| .flake8 | ||
| .gitignore | ||
| CHANGELOG.md | ||
| LICENSE | ||
| mkdocs.yml | ||
| noxfile.py | ||
| poetry.lock | ||
| pyproject.toml | ||
| README.md | ||
django-svg-sprite
A Django template tag for easy use of SVG sprites in templates.
Quick start
-
Add
django_svg_spriteto yourINSTALLED_APPSsetting like this:INSTALLED_APPS = [ ..., 'django_svg_sprite', ] -
Set the
SVG_SPRITEsetting to the SVG sprite file in your static files to be used, e.g.:SVG_SPRITE = 'bootstrap-icons.svg' -
Use the tag in your template, e.g.:
{% load svg_sprite %} {% svg_sprite 'hand-thumbs-up' fill='yellow' class='bi' %}
See settings and template tags documentation for details.
Commercial support
Commercial support, including feature development, is available. Get in contact.
License
This project is licensed under the MIT license.