Skip to content

Commit

Permalink
Let’s migrate the home page to WebC
Browse files Browse the repository at this point in the history
  • Loading branch information
zachleat committed Mar 3, 2023
1 parent b8b2d3d commit a7485d0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/index.md → src/index.webc
Expand Up @@ -16,6 +16,8 @@ eleventyComputed:
eleventyImport:
collections: ["blog"]
---
<template webc:type="11ty" 11ty:type="njk,md" webc:raw webc:nokeep>
{# we use webc:raw webc:nokeep so the template assets are not re-bundled as WebC yet #}
{%- set highlightedBlogPost = collections.blog | findBy("data.homePageHighlight", true) | first %}
{%- if highlightedBlogPost %}
{% callout %}<strong><a href="{{ highlightedBlogPost.data.page.url }}">{{ highlightedBlogPost.data.newstitle }}</a></strong> and more on the <a href="/blog/">Eleventy Blog</a>.{% endcallout %}
Expand Down Expand Up @@ -108,4 +110,4 @@ View [all {{ builtwith | objectFilterNot("disabled") | length }} sites](/speedli
Listen to what these [happy developers](/docs/testimonials/) are saying about Eleventy:

{% include "testimonials.md" %}

</template>

0 comments on commit a7485d0

Please sign in to comment.