相关疑难解决方法(0)

Pandoc:具有YAML元数据的模板

我使用pandoc生成带有YAML元数据的index.html.我知道pandoc模板中的迭代关联数组:

YAML:

- Author: Mastropiero
- Author: Gunter Fraggen
Run Code Online (Sandbox Code Playgroud)

模板:

$for(author)$
  $author$
$endfor$
Run Code Online (Sandbox Code Playgroud)

但是......如何在没有密钥的情况下迭代列表?

YAML:

- Author:
  - [Value1, Value2]
  - [Value1B, Value2B]
Run Code Online (Sandbox Code Playgroud)

模板:

$for(author)$
  ... // how works?
$endfor$
Run Code Online (Sandbox Code Playgroud)

arrays templates yaml pandoc

6
推荐指数
1
解决办法
3247
查看次数

标签 统计

arrays ×1

pandoc ×1

templates ×1

yaml ×1