Mitigate #171 by using js front matter type instead of YAML.
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
---
|
||||
eleventyNavigation:
|
||||
key: Home
|
||||
order: 1
|
||||
numberOfLatestPostsToShow: 3
|
||||
---js
|
||||
const eleventyNavigation = {
|
||||
key: "Home",
|
||||
order: 1
|
||||
};
|
||||
|
||||
const numberOfLatestPostsToShow = 3;
|
||||
---
|
||||
{% set postsCount = collections.posts | length %}
|
||||
{% set latestPostsCount = postsCount | min(numberOfLatestPostsToShow) %}
|
||||
|
||||
Reference in New Issue
Block a user