W3C
Slides at florian.rivoal.net{{ page.url }}
[...] includes only specifications that we consider stable and for which we have enough implementation experience that we are sure of that stability.
蒂姆伯李
<body>
<header>Header</header>
<main>Lorem Ipsum…</main>
<nav>Navigation</nav>
<aside>Commercials</aside>
<footer>Footer</footer>
</body>
body {
display: grid;
grid: "head head head" 3em
"nav main ads"
"foot foot foot" 2em
/ 1fr auto 1fr;
min-height: 100vh;
}
header { grid-area: head }
footer { grid-area: foot }
main { grid-area: main }
nav { grid-area: nav }
aside { grid-area: ads }
@media (width<24em) { body {
grid-template:
"head head" 3em
"nav main" 2fr
"ads main" 1fr
"foot foot" 2em
/ 1fr auto }}
@media (width<18em) { body {
display: block }}
display: contents
Suppress a box while keeping its descendants
<main> <h1>foo</h1> <ul><li>bar<li>baz</ul> </main>
main { display: flex } main * { flex: 1 }
ul { display: contents }
display: content
: statusBe wary of gaps and sharp edges
but use it in production today
and come help push it all forward.