I have created a page for a category categories.hbs
collection for the blog .Dynamic routing will add it to the website but it will not work. I also created a blank page for the slug at the back end but it doesn’t work properly.
routes:
/categories/:
data: page.categories
template: categories
collections:
/:
permalink: /{slug}/
template: index
taxonomies:
tag: /tag/{slug}/
author: /author/{slug}/
The hbs page included for that
{{!< default}}
<header class="site-header outer border-primary-top">
<div class="inner-header">
<nav class="site-nav">
<div class="site-nav-left">
<a class="site-nav-logo" href="{{@site
.url}}" aria-label="{{@site
.title}}">
<img src="{{@site
.logo}}">
</a>
</div>
<div class="inner-header">
<div class="category-holder">
<ul class="nav category-nav pull-right">
<li class="nav-tag"><a href="/tag/articles/" title="Articals">Articals</a></li>
<li class="nav-tag"><a href="/tag/news/" title="News">News</a></li>
<li class="nav-tag"><a href="/tag/Tutorials/" title="Tutorials">Tutorials</a></li>
<li>
<a href="/categories">
<span style="margin-left:0.5rem;">More...</span>
</a>
</li>
</ul>
<a class="search-btn no-decoration pull-right" href="#searchinghost-easy">
<span style="color: white;">
<i class="material-icons"></i>
</span>
</a>
<a class="category-search no-decoration category-xs" href="/categories">
<span style="margin-right:1.5rem;"> <i class="material-icons">menu</i></span>
</a>
</a>
</div>
</div>
</nav>
</div>
</header>
{{> header-background background=feature_image}}
{{!--Special header-image.hbs partial to generate the background image--}}
<div class="inner site-header-content">
<h1 class="site-title">categories</h1>
<h2 class="site-description">
{{#if description}}
{{description}}
{{else}}
A collection of {{plural ../pagination.total empty='posts' singular='% post' plural='% posts'}}
{{/if}}
</h2>
</div>
</div>
</header>
<main id="site-main" class="site-main outer">
<div class="inner">
<div class="inner posts">
<div class="post-feed">
{{#get "tags" limit="all" order="count.posts desc" include="count.posts" as |authors|}}
{{#foreach authors}}
<article class="post-card">
<a class="post-card-image-link no-decoration" href="{{url}}" style="color:#ffffff;">
<div class="post-card-image cat-img"
style="background-image: url({{#if feature_image}}{{feature_image}}{{else}}{{asset "images/category-cover.jpg?tr=h-200,w-381"}}{{/if}})">
<h2 class="post-card-title category-title text-center">{{name}}</h2>
</div>
</a>
<span class="post-card-tags pull-left author-post-count"><a href="{{url}}"
style="color:#ffffff;">{{plural count.posts empty='No articles' singular='% article' plural='% articles'}}</a></span>
<div class="post-card-content">
<a class="post-card-content-link" href="{{url}}">
<section class="post-card-excerpt text-center">
<p></p>
<p>
{{#if description}}
{{description}}
{{else}}
{{name}} යටතේ ලැයිස්තුගත කර ඇති news article {{count.posts}} ක් මේ යටතේ ඇත.
{{/if}}
</p>
</section>
</a>
<footer class="post-card-meta">
<ul class="author-list">
</ul>
<span class="reading-time"></span>
</footer>
</div>
</article>
{{/foreach}}
{{/get}}
</div>
</div>
</div>
</main>
Why does this not work?