Skip to content

h1

创建一级标题。

语法

knap
{{ value | h1 }}

用法

  • 数据的每个非空行都会成为一个标题。
  • 对于数组和对象(包括来自其他过滤器、已序列化的集合),其中的字符串取值会被递归格式化,而键和非字符串取值保持不变。

示例

Data
json
{
  "title": "Introduction"
}
Template
knap
{{ title | h1 }}
Output
md
# Introduction