【发布时间】:2022-08-15 07:21:02
【问题描述】:
我有一个从数据文件中提取数据的循环。我想要它拉动的东西之一是一个图标,无论是 svg 代码或文件,还是一个图像文件,任何可行的。
数据文件example.yml:
- title: Lorem title
description: Lorem description
icon: [icon code or file?]
循环示例:
{% for item in site.data.example %}
<span>{{ item.icon }}</span>
<h3>{{ item.title }}</h3>
<p>{{ item.description</p>
{% endfor %}
这能以某种方式工作吗?
标签: jekyll