Layouts (Frontend)
ELI5 — The Vibe Check
Layouts are like the floor plan of your website. Just like an architect decides where the kitchen and bathroom go, layouts decide where the header, sidebar, and content live. Without one, your site looks like a toddler arranged the furniture.
Real Talk
Frontend layouts define the structural arrangement of UI components on a page. Modern approaches use CSS Grid and Flexbox to create responsive, maintainable page structures that adapt to different screen sizes.
Show Me The Code
<div class="grid grid-cols-[240px_1fr] gap-4">
<aside>Sidebar</aside>
<main>Content</main>
</div>
When You'll Hear This
"The dashboard layout uses a fixed sidebar with a scrollable main area" / "We need a new layout for the marketing pages"
Related Terms
CSS Grid
CSS Grid is the two-dimensional layout system — rows AND columns at the same time. Think of it like a spreadsheet you can put your whole website into.
Flexbox
Flexbox is a CSS layout system that makes positioning elements in a row or column stupidly easy.
Responsive Design
Responsive design means your website looks good on EVERY screen size — from a tiny phone to a giant 4K monitor.