Hey
So on the tag pages it dynamically creates a list of posts that have that tag. On the tag pages we have added a sidebar which adds a list of static posts that we want to stay there all the time. The only thing is we want each tag page to have its own list of pages. So I was wondering if there was a way to filter the list of pages so that way the only ones displayed are the ones that are related to the tag.
Currently I have this.
<aside class="blog-sidebar">
{{#get "pages" as |pages-list|}}
{{#if pages-list}}
<section class="navbar" style="padding-bottom:90px; padding-top:10px">
{{#foreach pages}}
<a style="text-decoration: none" href="{{url}}"><section class="post-card post"><h2 style="margin-top:20px">{{title}}</h2></section></a>
{{/foreach}}
</section>
{{else}}
<p>Coming Soon</p>
{{/if}}
{{/get}}
</section>
</aside>
We tried this to filter it but it ended up just showing nothing rather than any pages at all.
<aside class="blog-sidebar">
{{#get "pages" filter="tags:{{slug}}" as |pages-list|}}
{{#if pages-list}}
<section class="navbar" style="padding-bottom:90px; padding-top:10px">
{{#foreach pages}}
<a style="text-decoration: none" href="{{url}}"><section class="post-card post"><h2 style="margin-top:20px">{{title}}</h2></section></a>
{{/foreach}}
</section>
{{else}}
<p>Coming Soon</p>
{{/if}}
{{/get}}
</section>
</aside>