Lists in HTML

작성자

카테고리:

← 피드로
DEV Community · Jaisurya · 2026-07-11 개발(SW)

Jaisurya

In HTML, lists are used to group related items together. There are different types of list in HTML. They are,

1. Unordered list:
Used for items where the order does not matter. By default, these items are displayed with bullet points.

<ul>
  <li>Water</li>
  <li>Coffee</li>
  <li>Tea</li>
</ul>

Enter fullscreen mode Exit fullscreen mode

2. Ordered list:
Used for items where the sequence or order matters.By default, these are displayed with numbers.

<ol>
  <li>Cake</li>
  <li>Chocalate</li>
  <li>Juice</li>
</ol>

Enter fullscreen mode Exit fullscreen mode

3. Description List
Used for pair of terms and description.

<dl>
  <dt>HTML</dt>
  <dd>HyperText Markup Language</dd>

  <dt>CSS</dt>
  <dd>Cascading Style Sheets.</dd>
</dl>

Enter fullscreen mode Exit fullscreen mode

원문에서 계속 ↗

추출 본문 · 출처: dev.to · https://dev.to/jaisurya/lists-in-html-2da2

코멘트

답글 남기기

이메일 주소는 공개되지 않습니다. 필수 필드는 *로 표시됩니다