---
pagination:
data: collections.recipesBySlug
size: 1
alias: slugData
resolve: keys
permalink: /recipe/{{ slugData }}/
layout: base.njk
excludeFromSitemap: true
eleventyComputed:
title: "{{ collections.recipesBySlug[slugData].newest.data.title }}"
---
{% set recipeData = collections.recipesBySlug[slugData] %}
{% set recipe = recipeData.newest %}
{% if recipe %}
{{ recipe.content | safe }}
{% set recipeTags = recipe.inputPath | extractTagsFromFile %}
{% if recipeTags.length > 0 %}
{% endif %}
{% set nonDraftVersions = [] %}
{% for version in recipeData.versions %}
{% if not version.data.isDraft %}
{% set nonDraftVersions = (nonDraftVersions.push(version), nonDraftVersions) %}
{% endif %}
{% endfor %}
{% if nonDraftVersions.length > 1 %}
{% endif %}
{% else %}
No published recipe found for this slug.
{% endif %}