How to correctly use “section” tag in HTML5?

前端 未结 6 1455
囚心锁ツ
囚心锁ツ 2020-12-02 04:59

I\'m trying to build a layout in HTML5 and after reading several different articles I\'m just confused. I\'m trying to get some input on how it should be used.

Below

6条回答
  •  天涯浪人
    2020-12-02 05:23

    You can definitely use the section tag as a container. It is there to group content in a more semantically significant way than with a div or as the html5 spec says:

    The section element represents a generic section of a document or application. A section, in this context, is a thematic grouping of content, typically with a heading. http://www.w3.org/TR/html5/sections.html#the-section-element

提交回复
热议问题