---
title: Main Tag
localeTitle: 主日
---
## 主标签

`<main>`标记的工作方式类似于`<div>`标记，但在语义上表示文档的主要内容或文档的一部分。可以使用多个`<main>`标签，例如用于各种物品的主要内容，因此其内容应该对于文档是唯一的并且不在别处重复。

### 例

以下示例说明了`<main>`标记的用法：

```html

<!-- other content --> 
 
 <main> 
  <h1>Diary Entry 31</h1> 
  <p>Oct 23 2017</p> 
 
  <article> 
    <h2>Today Is Unique</h2> 
    <p>This information will be unique among other articles.</p> 
  </article> 
 </main> 
 
 <!-- other content --> 

```