Description list dùng cho cặp thuật ngữ-định nghĩa hoặc key-value pairs. <dl> bọc toàn bộ, <dt> (term) là thuật ngữ, <dd> (description) là giải thích.
- Một
<dt>có thể có nhiều<dd>. - Phù hợp nhất cho: FAQ (câu hỏi là dt, câu trả lời là dd), glossary, metadata (Tác giả: ..., Ngày: ..., Thể loại: ...).
- Lỗi hay gặp: dùng
<ul>+<li>cho danh sách key-value vì tiện hơn, nhưng<dl>semantic và accessible hơn.
Description lists are for term-definition pairs or key-value data. <dl> wraps the whole list, <dt> (term) is the term, <dd> (description) is the definition.
- A single
<dt>can have multiple<dd>elements. - Best suited for: FAQ (question as dt, answer as dd), glossaries, metadata (Author: ..., Date: ..., Category: ...).
- Common mistake: using
<ul>+<li>for key-value lists because it feels simpler — but<dl>is more semantic and accessible.