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
{
"data":
<a href="/universities/a/" class="no-underline pa3 bg-grey-1 br1 mb2 db raise w-100">
<h2 class="f3 b lh-title mb1 primary">A</h2>
<p class="mid-gray lh-title mb2">Mon, Jan 1, 0001</p>
<p class="mb0"></p>
<p class="link b dib black mb0">Read more →</p>
</a>
,
<a href="/universities/b/" class="no-underline pa3 bg-grey-1 br1 mb2 db raise w-100">
<h2 class="f3 b lh-title mb1 primary">A</h2>
<p class="mid-gray lh-title mb2">Mon, Jan 1, 0001</p>
<p class="mb0"></p>
<p class="link b dib black mb0">Read more →</p>
</a>
}
For whatever reason, the output for list renders the li.html template, but the json template is correctly rendered when rendering a single. This is inconsistent behavior.
Can anyone look into this?
Thanks
The text was updated successfully, but these errors were encountered:
I want Hugo to generate a JSON API alongside my pages. I am using the output formats feature, and the following layout templates in layouts/_default/
baseof.json.json
single.json.json
li.json.json
list.json.json
Rendering the html works fine. It only fails when outputing a list of json objects.
Output for single
Output for list
For whatever reason, the output for list renders the li.html template, but the json template is correctly rendered when rendering a single. This is inconsistent behavior.
Can anyone look into this?
Thanks
The text was updated successfully, but these errors were encountered: