[whatwg] <di>? Please?

Hugh Guiney hugh.guiney at gmail.com
Tue Jan 10 00:48:57 PST 2012


On Tue, Jan 10, 2012 at 2:52 AM, Jordan Dobson <jordandobson at gmail.com> wrote:
> Sounds like what you want is flex box. Have you looked at that yet?

I don't know flexbox too well yet—how would one use it to create a
columnar <dl>? From what I can tell though, it still wouldn't allow me
to style <dt>/<dd> pairings as a single unit, which is actually the
root issue here.

On Tue, Jan 10, 2012 at 3:04 AM, Bruce Lawson <brucel at opera.com> wrote:
> Seems to me no need to add a new element. If <div> could be a child of <dl>
> then you could use that.
>
> However, it can't. I don't know why, though.

I would probably avoid <div> in this case simply because it's supposed
to be semantically blank; in the example I gave, if <section> were
<div> instead, it would be completely appropriate for an outliner to
regard that as two sections instead of three. So, if we're going to
reuse an element like that, I'd lean more toward <section>—although I
can't recommend this either as it implies that bits and pieces of
<dl>s should show up in the document outline.

I think that <di> or <li> or even <dl> children of <dl> (all of which
have been suggested in the past) make the most sense here. As a
developer it doesn't matter to me which one it is; I could just use
the flexibility.



More information about the whatwg mailing list