Don't show Ingredients/Steps h3 when there are none
This commit is contained in:
parent
347231f013
commit
dcb566275c
1 changed files with 4 additions and 0 deletions
|
@ -17,14 +17,18 @@
|
||||||
{{getrecipe(subrecipe)}}
|
{{getrecipe(subrecipe)}}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
<h1>{{rec.title}}</h1>
|
<h1>{{rec.title}}</h1>
|
||||||
|
{% if rec.ingredients|length != 0 %}
|
||||||
<h3>Ingredients</h3>
|
<h3>Ingredients</h3>
|
||||||
{% for ing in rec.ingredients %}
|
{% for ing in rec.ingredients %}
|
||||||
<li>{{ingredient(ing)}}</li>
|
<li>{{ingredient(ing)}}</li>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
{% endif %}
|
||||||
|
{% if rec.steps|length != 0 %}
|
||||||
<h3>Steps</h3>
|
<h3>Steps</h3>
|
||||||
{% for step in rec.steps %}
|
{% for step in rec.steps %}
|
||||||
<li>{{ step }}</li>
|
<li>{{ step }}</li>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
{% endif %}
|
||||||
<hr>
|
<hr>
|
||||||
{%- endmacro %}
|
{%- endmacro %}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue