我是 JBake 的新手。我看到了创建索引页面的默认方式。
<#list posts as post>
<#if (post.status == "published")>
-- design your posts here
</#if>
</#list>
这会按降序排列所有帖子。
这看起来很棒,只有一个问题,我不知道如何突出显示我的最新帖子。
所以我想做类似的事情,
<#list posts as post>
<#if (post.status == "published")>
<#if (this is latest post)>
use highlighted style
</#if>
<#if (this is not a latest post)>
use normal style
</#if>
</#if>
</#list>
我怎样才能做到这一点?