Skip to content

Commit 23a51ac

Browse files
committed
Upgrade to WebC v0.11.0
1 parent f730b28 commit 23a51ac

File tree

5 files changed

+24
-25
lines changed

5 files changed

+24
-25
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"@11ty/eleventy-navigation": "^0.3.5",
5151
"@11ty/eleventy-plugin-rss": "^1.2.0",
5252
"@11ty/eleventy-plugin-syntaxhighlight": "^4.2.0",
53-
"@11ty/eleventy-plugin-webc": "^0.10.1",
53+
"@11ty/eleventy-plugin-webc": "^0.11.0",
5454
"@netlify/functions": "^1.4.0",
5555
"@netlify/plugin-lighthouse": "^4.0.7",
5656
"@tweetback/canonical": "^2.0.29",

src/_includes/components/cli-eleventy-output.webc

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
}
66
</style>
77
<script webc:type="js">
8-
let version = latestVersion(versions, config);
8+
let version = latestVersion($data.versions, $data.config);
99
let versionSuffix = showVersion === "" ? ` (${version})` : "";
1010
this.helpers.highlight("bash", `${this.slots.text.default.trim()}${versionSuffix}`, "/", "-"); // `"/", "-"` enables line wrapping
1111
</script>
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
<span webc:nokeep @text="latestVersion(versions, config, prefix)"></span>
1+
<span webc:nokeep @text="latestVersion($data.versions, $data.config)"></span>

src/_includes/components/node-minimum.webc

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ function latestVersionNodeMinimum(versions, config) {
1616
}
1717
</script>
1818

19-
<span webc:nokeep @text="latestVersionNodeMinimum(versions, config)"></span>
19+
<span webc:nokeep @text="latestVersionNodeMinimum($data.versions, $data.config)"></span>

src/index.webc

+20-21
Original file line numberDiff line numberDiff line change
@@ -16,29 +16,29 @@ let searchTitle = "Eleventy, a simpler static site generator";
1616
let skipAuth = true;
1717

1818
let eleventyImport = {
19-
collections: ["blog"]
19+
collections: ["blog"]
2020
};
2121

2222
let eleventyComputed = {
23-
social: {
24-
description: () => "Eleventy, a simpler static site generator."
25-
},
23+
social: {
24+
description: () => "Eleventy, a simpler static site generator."
25+
},
2626
};
2727
// </script>
2828
---
2929
<script webc:setup>
3030
function getHighlightedBlogPostContent(collection) {
31-
let posts = findBy(collection, 'data.homePageHighlight', true);
32-
if(!posts.length) {
33-
return "";
34-
}
31+
let posts = findBy(collection, 'data.homePageHighlight', true);
32+
if(!posts.length) {
33+
return "";
34+
}
3535

36-
let content = [];
37-
for(let post of posts) {
38-
content.push(`<strong><a href="${post.data.page.url}">${post.data.newstitle}</a></strong>`);
39-
}
36+
let content = [];
37+
for(let post of posts) {
38+
content.push(`<strong><a href="${post.data.page.url}">${post.data.newstitle}</a></strong>`);
39+
}
4040

41-
return `Read ${content.join(" and ")} <em>(and more!)</em> on the <a href="/blog/">Eleventy Blog</a>.`;
41+
return `Read ${content.join(" and ")} <em>(and more!)</em> on the <a href="/blog/">Eleventy Blog</a>.`;
4242
}
4343
</script>
4444

@@ -59,11 +59,10 @@ function getHighlightedBlogPostContent(collection) {
5959
<p>From a <a href="https://www.zachleat.com/web/build-benchmark/#benchmark-results">benchmark of ×4000 markdown files</a>. Learn more about <a href="/docs/performance/">Eleventy’s site and build performance</a>.</p>
6060

6161
<quick-start></quick-start>
62-
6362
<hr>
6463

6564
<div class="fullwidth-module">
66-
<logo-cloud></logo-cloud>
65+
<logo-cloud></logo-cloud>
6766
</div>
6867

6968
<giant-docs-button></giant-docs-button>
@@ -88,11 +87,11 @@ function getHighlightedBlogPostContent(collection) {
8887
<sites-list-njk :sites="builtwith"></sites-list-njk>
8988

9089
<div class="fullwidth-module">
91-
<is-land on:visible on:save-data="false">
92-
<facepile>
93-
<html-fetch src="/imports/facepile.html"></html-fetch>
94-
</facepile>
95-
</is-land>
90+
<is-land on:visible on:save-data="false">
91+
<facepile>
92+
<html-fetch src="/imports/facepile.html"></html-fetch>
93+
</facepile>
94+
</is-land>
9695
</div>
9796

9897
<p>View <a href="/speedlify/">all <span @text="getsize(objectFilterNot(builtwith, 'disabled'))" webc:nokeep></span> sites</a>.</p>
@@ -101,7 +100,7 @@ function getHighlightedBlogPostContent(collection) {
101100

102101
<p>Listen to what these <a href="/docs/testimonials/">happy developers</a> are saying about Eleventy:</p>
103102

104-
<testimonials-list></testimonials-list>
103+
<testimonials-list :testimonials="testimonials"></testimonials-list>
105104

106105
<p><a href="/docs/testimonials/">…and many more!</a></p>
107106
</div>

0 commit comments

Comments
 (0)