django_spire/core/management/commands/spire_opencode_pkg/skills/list_templates/SKILL.md
Examples on how we implement our list templates (pages, cards, items).
npx skillsauth add stratusadv/django-spire list-templatesInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
list_page.html
{% extends 'django_spire/page/full_page.html' %}
{% block full_page_content %}
<div class="row">
<div class="col-12">
{% include 'friend/card/list_card.html' %}
</div>
</div>
{% endblock %}
list_card.html
{% extends 'django_spire/card/title_card.html' %}
{% block card_title %}
Friends
{% endblock %}
{% block card_button %}
{% if perms.friend.add_friend %}
{% url 'mort:friend:form:create' as new_friend_url %}
{% include 'django_spire/button/primary_dark_button.html' with button_text='Add' button_icon='bi bi-plus' button_href=new_friend_url %}
{% endif %}
{% endblock %}
{% block card_title_content %}
{% for friend in friends %}
{% include 'friend/item/item.html' %}
{% empty %}
{% include 'django_spire/item/no_data_item.html' %}
{% endfor %}
{% endblock %}
item.html
{% extends 'django_spire/item/item.html' %}
{% block item_title %}
{% url 'mort:friend:page:detail' pk=friend.pk as friend_view_url %}
{% include 'django_spire/element/attribute_element.html' with attribute_title='Friend' attribute_value=friend.first_name attribute_href=friend_view_url %}
{% endblock %}
{% block item_row_content %}
<div class="col-6">
{% include 'django_spire/element/attribute_element.html' with attribute_title='Last Name' attribute_value=friend.last_name %}
</div>
{% endblock %}
{% block item_button %}
{% url 'mort:friend:page:detail' pk=friend.pk as friend_view_url %}
{% if perms.friend.change_friend %}
{% url 'mort:friend:form:update' pk=friend.pk as friend_edit_url %}
{% endif %}
{% if perms.friend.delete_friend %}
{% url 'mort:friend:form:delete' pk=friend.pk as friend_delete_url %}
{% endif %}
{% include 'django_spire/dropdown/ellipsis_dropdown.html' with view_url=friend_view_url edit_url=friend_edit_url delete_url=friend_delete_url %}
{% endblock %}
development
How to implement table templates in Django Spire.
development
How to implement tab templates in Django Spire.
development
Service layer best practices on django models
development
Best practices for seeding django models