Re: Guide/AlternateElementTemplate

2007/12/6, Doug Jones:
>
> On 2007 Dec 05, at 18:54, Steve Axthelm wrote:
> >
> > In the Tags section, do also need to document if an element's start
> > and end tags are optional?
> >
> > So:
> >
> > == Tags ==
> > :: Start tag:
> >    [<tag> or <tag/> if void]
> >    [Required | Optional (state where tag is implied if optional)]
> > :: End tag:
> >    [</tag> or the word none if void]
> >    [Required | Optional (state where tag is implied if optional)]
> >
>
> I believe all tags should always be used by anyone writing to the
> HTML5 spec. There are backward compatibility issues that UAs have to
> take into account, but new documents should be encouraged to be
> explicit. So, optional use of tags should not be detailed in the Web
> Developers Guide. Yes, I have to teach myself to use <tbody>.

That's a matter of taste.

> BTW, the spec does not, in defining elements, state any are optional
> except where the structure they represent is itself optional (<thead>
> within <table>, for instance).

http://www.whatwg.org/specs/web-apps/current-work/multipage/section-writing0.html#optional
or, for the W3C version (not "multipage" though):
http://www.w3.org/html/wg/html5/#optional

Tags are not related to elements but to serialization/representation,
that's why their optionality is described in the "Writing" section,
not within the elements' description.

-- 
Thomas Broyer

Received on Thursday, 6 December 2007 08:31:44 UTC