1
我试图表明标签云在我的博客杰基尔像下面我不能让.size杰基尔
https://superdevresources.com/tag-cloud-jekyll/
,但是,我不能访问tag.tags site.tags [some_tag。大小
这是sidebar.html
{% assign tags = site.tags | sort %}
{% for tag in tags %}
<span>
<a href="/tags/{{ tag.slug }}" class="tag-reverse">
<span>{{ tag.name }}</span>
<span>({{ tag.tags.size }})</span>
^This is always null
</a>{% unless forloop.last %}{% endunless %}
</span>
{% endfor %}
我认为,tag.tags
size
为代表的SP的职位数目码ecific标签。但空一直来,即使有在标签
FYI职位,这是一些_config.xml
# Tags
collections:
tags:
output: true
permalink: /tags/:path/
defaults:
- scope:
path: ''
type: tags
values:
layout: tag
你可以在https://github.com/closer27/closer27.github.io达到我的博客回购
谢谢你对我的帮助
谢谢你,我不知道模板杰奇。但是当我把你的代码放在我的源代码中时,我可以在每个循环中获得'31',而不是每个标签的大小。我认为这是所有帖子的计数,我正在寻找一个正确的表达式 – Seungwon
哦,我明白了。 'where_exp'在v3.2.0上可用。所以我更新了jekyll并完成了。 – Seungwon