From dcb566275cdb061a0c2bef59d42adaa5e6e07a5f Mon Sep 17 00:00:00 2001 From: Emi Vasilek Date: Mon, 6 Nov 2023 23:32:24 +0100 Subject: [PATCH] Don't show Ingredients/Steps h3 when there are none --- templates/recipe.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/templates/recipe.html b/templates/recipe.html index fc31df2..fb130d7 100644 --- a/templates/recipe.html +++ b/templates/recipe.html @@ -17,14 +17,18 @@ {{getrecipe(subrecipe)}} {% endfor %}

{{rec.title}}

+{% if rec.ingredients|length != 0 %}

Ingredients

{% for ing in rec.ingredients %}
  • {{ingredient(ing)}}
  • {% endfor %} +{% endif %} +{% if rec.steps|length != 0 %}

    Steps

    {% for step in rec.steps %}
  • {{ step }}
  • {% endfor %} +{% endif %}
    {%- endmacro %}