Closed tao closed 3 years ago
I've actually come across this issue again so I'm going to re-open it and investigate it some more.
The video is coming from a different collection too, so the {{ video }} tag must not be clearing properly between pages.
I found the only way to overcome this issue for now is to give each collection it's own dedicated index/show pages instead of using a global template. I tried to figure out a way to solve the problem in the ssg codebase but nothing helped.
The {{ video }}
was being show in another collection that didn't even have a video
in the blueprint, and I also tried clearing the stache each time before testing. So it's really a difficult issue for me to understand what's going on.
I believe I found another example where this might be causing an issue... I'm generating my static site and some pages have redirects with antlers:
{{ redirect to="/library/books" }}
This works fine until SSG renders a collection with redirect: 'entry::id'
in the yaml header and I start getting a new problem:
[✘] /books/2019 (Modifier [to] not found)
I believe because it's not clearing data after each render, antlers tries to print the variable redirect
from the previous collection... then tries to modify it with to
- instead of generating a redirect as intended.
I have a similar issue: comments from a blogpost are generated until a blogpost has new comments. Then those comments are generated on all blogposts until there's a post with new comments.
I have a very simple default page template which I use for many collections, and I check if a video exists with the video tag and display it at the top of the page. I generated the static site and one of the videos from a file appeared on every single page using this template. Which I don't quite understand how but it's an interesting problem. So even collections that don't have a video tag in the blueprint at all, now have the same video at the top of the page, so the data must not have been cleared from a previous page?