djhtml icon indicating copy to clipboard operation
djhtml copied to clipboard

Not working with django-template-partials

Open Thutmose3 opened this issue 1 year ago • 0 comments

I'm using django-template-partials (https://github.com/carltongibson/django-template-partials) Its a nice library to create small components to be reused in templates.

This library has 2 template tags and it formats them wrong:

<div class="grid grid-cols-12 gap-4">
    {% partial product_dimensions %}
        <div class="sm:col-span-5">

It should be like this:

<div class="grid grid-cols-12 gap-4">
    {% partial product_dimensions %}
    <div class="sm:col-span-5">

This is the other template tag that is wrongly formatted:

<div class="w-full">
    {% startpartial product_images %}
    {% for image in images %}
        {{ image }}
    {% endfor %}
    {% endpartial %}
</div>

It should be like this:

<div class="w-full">
    {% startpartial product_images %}
        {% for image in images %}
            {{ image }}
        {% endfor %}
    {% endpartial %}
</div>

Thutmose3 avatar Feb 18 '24 12:02 Thutmose3