LOADING
310 字
2 分钟

暮光指南:入門

Guide for Template - Getting Started

翻譯提示 (未審閱)

此頁面由 AI 翻譯生成,可能存在不準確之處。

翻譯自: 🇬🇧 English (Deepseek)

檢視原文 回到譯文

提示:本指南未提及的內容,您可以在 Astro 文件 中找到解答。

文章的 Front-matter

---
title: My First Blog Post
published: 2020-02-02
description: This is the first post of my new Astro blog.
cover: ./cover.jpg
coverInContent: false
tags: []
category: Guides
comment: true
draft: false
translation:
type: "human"
reviewed: true
---
屬性說明
title文章標題。
published文章發布日期。
pinned是否將此文章置頂於文章列表頂端。
description文章的簡短描述。顯示於首頁。
cover文章的封面圖片路徑。
1. 以 http://https:// 開頭:網路圖片
2. 以 / 開頭:位於 public 目錄的圖片
3. 無上述前綴:相對於 markdown 檔案的路徑
coverInContent是否在文章內容中顯示封面圖片。
tags文章的標籤。
category文章的分類。
1. 單一分類:category: Guides
2. 多層分類:category: [Guides, Getting Started]
licenseName文章內容的授權名稱。
author文章的作者。
sourceLink文章內容的來源連結或參考資料。
comment是否啟用此文章的留言功能。預設為 true
draft若此文章仍為草稿,則不會顯示。

文章檔案放置位置

您的文章檔案應放置在 src/content/posts/ 目錄中。您也可以建立子目錄,以便更好地組織文章和資源。

src/content/posts/
├── post-1.md
└── post-2/
├── cover.jpg
└── index.md

Tip: For the things that are not mentioned in this guide, you may find the answers in the Astro Docs.

Front-matter of Posts

---
title: My First Blog Post
published: 2020-02-02
description: This is the first post of my new Astro blog.
cover: ./cover.jpg
coverInContent: false
tags: []
category: Guides
comment: true
draft: false
translation:
type: "human"
reviewed: true
---
AttributeDescription
titleThe title of the post.
publishedThe date the post was published.
pinnedWhether this post is pinned to the top of the post list.
descriptionA short description of the post. Displayed on index page.
coverThe cover image path of the post.
1. Start with http:// or https://: For web image
2. Start with /: For image in public dir
3. With none of the prefixes: Relative to the markdown file
coverInContentWhether to show the cover image in the post content.
tagsThe tags of the post.
categoryThe category of the post
1. Single category: category: Guides
2. Multi-category: category: [Guides, Getting Started]
licenseNameThe license name for the post content.
authorThe author of the post.
sourceLinkThe source link or reference for the post content.
commentWhether to enable comment for this post. Default is true.
draftIf this post is still a draft, which won’t be displayed.

Where to Place the Post Files

Your post files should be placed in src/content/posts/ directory. You can also create sub-directories to better organize your posts and assets.

src/content/posts/
├── post-1.md
└── post-2/
├── cover.jpg
└── index.md
暮光指南:入門
/zh-TW/posts/twilight-guide-getting-started/
作者
MuxBuffer
发布于
2001-10-02
许可协议
CC BY-NC-SA 4.0
AI參與指數 IIIA-0
分類 未經AI製作
等級 0
簡介 完全未使用AI

此页面可能不是最新版本。