feat: add a better integration of the authors
parent
63aa82a960
commit
9520f303ea
|
@ -104,7 +104,10 @@ module.exports = function(eleventyConfig) {
|
||||||
});
|
});
|
||||||
|
|
||||||
eleventyConfig.addFilter("readableAuthors", (authors) => {
|
eleventyConfig.addFilter("readableAuthors", (authors) => {
|
||||||
return authors ? "par " + (authors || []).join(" & ") : "";
|
if (authors.length > 1) {
|
||||||
|
return "par " + authors.slice(0, -1).join(", ") + " et " + authors.slice(-1);
|
||||||
|
}
|
||||||
|
return "par " + (authors || []);
|
||||||
});
|
});
|
||||||
|
|
||||||
eleventyConfig.addFilter("noHome", elements => {
|
eleventyConfig.addFilter("noHome", elements => {
|
||||||
|
|
Loading…
Reference in New Issue