feat: remove home page from other links
This commit is contained in:
@@ -85,6 +85,12 @@ module.exports = function(eleventyConfig) {
|
||||
return authors ? "par " + (authors || []).join(" & ") : "";
|
||||
});
|
||||
|
||||
eleventyConfig.addFilter("noHome", elements => {
|
||||
return elements.filter(e => {
|
||||
return e.url !== '/';
|
||||
});
|
||||
})
|
||||
|
||||
// Customize Markdown library and settings:
|
||||
eleventyConfig.amendLibrary("md", mdLib => {
|
||||
mdLib.use(markdownItAnchor, {
|
||||
|
@@ -1,6 +1,6 @@
|
||||
<div class="title">Autres liens</div>
|
||||
<ul class="links">
|
||||
{%- for entry in collections.all | eleventyNavigation %}
|
||||
{%- for entry in collections.all | eleventyNavigation | noHome %}
|
||||
<li><a
|
||||
href="{{ entry.url }}">{{ entry.title }}</a></li>
|
||||
{%- endfor %}
|
||||
|
Reference in New Issue
Block a user