I’m trying to custom my homepage and here is my routes.yaml. I want to show all of post at homepage and then in the collection /city/culture i want to show only with them (city and culture).
But my homepage show the permalink to /{slug}, it is like /city/culture is overrided
routes:
collections:
/:
permalink: /{slug}/
template: home
/city/culture/:
permalink: /city/culture/{slug}/
template: index
filter: tag:[city, culture]
taxonomies:
tag: /tag/{slug}/
author: /author/{slug}/
Collections are exclusive. A post can’t be in two. Flipping the order will get you the URLs you want, but what’s listed as a /: collection should be /blog/ or something. (No need to change the permalinks.
You’ll want a channel for the / route, since you want the city/culture at / also. Check the docs for format.
You’re also going to need to change the filter, since a , means “or”. Try tag:city+tag:culture to require both.
I think you’re going to have a problem with this. Posts that aren’t either city or culture tagged will have no permalink. You’re going to need another collection.