mirror of
https://github.com/halo-dev/docs.git
synced 2026-01-16 07:01:06 +08:00
docs: update documentation for Halo 2.1 (#162)
为 Halo 2.1 更新文档。 see https://github.com/halo-dev/halo/releases/tag/v2.1.0 /kind documentation ```release-note None ```
This commit is contained in:
@@ -0,0 +1,65 @@
|
||||
---
|
||||
title: 文章
|
||||
description: post.html - /archives/:slug
|
||||
---
|
||||
|
||||
import CategoryVo from "../vo/CategoryVo.md"
|
||||
import TagVo from "../vo/TagVo.md"
|
||||
import ContentVo from "../vo/ContentVo.md"
|
||||
import Contributor from "../vo/Contributor.md"
|
||||
import PostVo from "../vo/PostVo.md"
|
||||
|
||||
## 路由信息
|
||||
|
||||
- 模板路径:`/templates/post.html`
|
||||
- 访问路径:`/archives/:slug`
|
||||
|
||||
## 变量
|
||||
|
||||
### post
|
||||
|
||||
#### 变量类型
|
||||
|
||||
[#PostVo](#postvo)
|
||||
|
||||
#### 示例
|
||||
|
||||
```html title="/templates/post.html"
|
||||
<article>
|
||||
<h1 th:text="${post.spec.title}"></h1>
|
||||
<div th:utext="${post.content.content}"> </div>
|
||||
</article>
|
||||
```
|
||||
|
||||
### _templateId
|
||||
|
||||
#### 变量值
|
||||
|
||||
`post`
|
||||
|
||||
## 类型定义
|
||||
|
||||
### CategoryVo
|
||||
|
||||
<CategoryVo />
|
||||
|
||||
### TagVo
|
||||
|
||||
<TagVo />
|
||||
|
||||
### Contributor
|
||||
|
||||
<Contributor />
|
||||
|
||||
### ContentVo
|
||||
|
||||
<ContentVo />
|
||||
|
||||
### PostVo
|
||||
|
||||
<PostVo />
|
||||
|
||||
- [#CategoryVo](#categoryvo)
|
||||
- [#TagVo](#tagvo)
|
||||
- [#Contributor](#contributor)
|
||||
- [#ContentVo](#contentvo)
|
||||
Reference in New Issue
Block a user