简体   繁体   中英

How to use section tag with angular js for make it responsive

Can I use angular js with three sectioning of the web page for make it responsive by making two sections into dropdown buttons

<body>
    <section id="main">
    <section id="body">
        // data in li
    </section>

    <aside id="side">
        //data with links
    </aside>
    </section>
</body>

The HTML section tag has no built in behaviour, it just denotes a section of the document, normally with its own heading, where other tags such as article or nav are not appropriate eg

<section id="my-section">
    <h2>Heading for section</h2>
    <p>Some content</p>
</section>

See https://developer.mozilla.org/en/docs/Web/HTML/Element/section

The HTML element represents a standalone section of functionality contained within an HTML document, typically with a heading, which doesn't have a more specific semantic element to represent it.

As an example, a navigation menu should be wrapped in a element, but a list of search results and a map display and its controls don't have specific elements, and could be put inside a .

So for making a responsive layout, using section over div or any other element does not really have any meaning. You must use CSS (eg with media queries) or JavaScript to change the layout (FYI, the default for section is display: block ).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM