You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to generate index-pages for my tags using pagination, pretty much following the Quick Tip from the documentation, except for the fact I recently ported my page to WebC instead of Liquid. However, I cannot figure out how to format the permalinks to generate the pages based on the tag-names, which in Liquid would've been done like so:
---
pagination:
data: collections
size: 1
alias: tag
filter: [all]
permalink: "tags/{{ tag }}/"
---
Using several permutations of guessing how to writr this in WebC, template-strings and javascript-style-frontmatter, I'm always getting something to the tune of
Eleventy:EleventyErrorHandler (error stack): DuplicatePermalinkOutputError: Output conflict: multiple input files are writing to `public/tags/{{ tag }}/index.html`. Use distinct `permalink` values to resolve this conflict.
Eleventy:EleventyErrorHandler 1. ./blog/tags/pagination.webc
Eleventy:EleventyErrorHandler 2. ./blog/tags/pagination.webc
Eleventy:EleventyErrorHandler 3. ./blog/tags/pagination.webc
I'm more confused by the fact that in another WebC-template, the double-curly format to generate my posts at date-based urls appears to be working fine:
---
layout: "_layouts/document.webc"
title: my title
permalink: "posts/{{ page.date | date: '%Y' }}/{{ page.date | date: '%m' }}/{{ page.date | date: '%d' }}/{{ title | slugify }}"
tags: post
---
is it because there are filters involved? I've spent several hours on this and am now stumped and feel stupid, would be thankful for a pointer or a workaround.
Reproduction steps
generate pages with dynamic permalinks including the tag-names using the pagination feature in a WebC-template
from those threads i learned that i have to format it like permalink: "'/tags/' + tag + '/'" (the difference to what i tried before being that nested quotes i think, as if eval-ing the string).
i'm also still hazy on why the liquid-style double curlies work in the other case illustrated in my original post, as that is also inside a .webc-file.
Operating system
Ubuntu 23.04
Eleventy
2.01
Describe the bug
I'm trying to generate index-pages for my tags using pagination, pretty much following the Quick Tip from the documentation, except for the fact I recently ported my page to WebC instead of Liquid. However, I cannot figure out how to format the permalinks to generate the pages based on the tag-names, which in Liquid would've been done like so:
Using several permutations of guessing how to writr this in WebC, template-strings and javascript-style-frontmatter, I'm always getting something to the tune of
I'm more confused by the fact that in another WebC-template, the double-curly format to generate my posts at date-based urls appears to be working fine:
is it because there are filters involved? I've spent several hours on this and am now stumped and feel stupid, would be thankful for a pointer or a workaround.
Reproduction steps
generate pages with dynamic permalinks including the tag-names using the pagination feature in a WebC-template
Expected behavior
pages are generated like
Reproduction URL
No response
Screenshots
No response
The text was updated successfully, but these errors were encountered: