explaingit

philipwalton/solved-by-flexbox

12,931CSSAudience · developerComplexity · 1/5Setup · easy

TLDR

A showcase website with working examples demonstrating how CSS Flexbox solves layout problems that were previously difficult or impossible, like sticky footers, equal-height columns, and vertical centering.

Mindmap

mindmap
  root((solved-by-flexbox))
    What it does
      CSS layout demos
      Flexbox examples
      Before and after
    Solved Patterns
      Sticky footer
      Equal height columns
      Vertical centering
    Tech Stack
      CSS
      Node.js
    Audience
      Web developers
      CSS learners
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Learn how to build a sticky footer with CSS Flexbox by studying a working demo and copying the clean solution.

USE CASE 2

Create equal-height columns in a layout using the Flexbox technique shown in the examples, without JavaScript hacks.

USE CASE 3

Vertically center content inside a container using the straightforward Flexbox approach instead of old CSS workarounds.

USE CASE 4

Run the site locally with Node.js, modify the Flexbox examples, and see changes in the browser instantly.

Tech stack

CSSNode.jsnpm

Getting it running

Difficulty · easy Time to first run · 5min

In plain English

Solved by Flexbox is a showcase website that demonstrates CSS layout problems that were once difficult or outright impossible to solve with CSS alone, and shows how those same problems are now straightforward using a CSS feature called Flexbox. Flexbox is a layout model built into modern web browsers that gives developers much finer control over how elements are sized, aligned, and distributed inside a container. Before Flexbox, common design patterns like vertically centering content, creating equal-height columns, or building sticky footers required elaborate CSS workarounds or JavaScript. This project catalogs those scenarios and presents clean Flexbox-based solutions with working examples. The repository is the source code for the showcase site, which is published at a public URL. To run it locally, you need Node.js installed, then install the dependencies with npm and start a local server. The site rebuilds automatically as you edit files, so you can experiment with the code and see changes in the browser right away. The project has been translated into Chinese, Japanese, and Korean by community contributors. The README notes these translations are unofficial and may be out of date. This is a reference and educational resource rather than a library or tool you install in another project. It is useful for web developers who want to understand what Flexbox is capable of, or who are looking for solutions to specific layout challenges.

Copy-paste prompts

Prompt 1
Using the Flexbox technique from solved-by-flexbox, show me the CSS to create a sticky footer that always stays at the bottom of the page even with little content.
Prompt 2
Based on the solved-by-flexbox examples, write CSS for a three-column layout where all columns are exactly the same height regardless of their content.
Prompt 3
I want to vertically center a card inside a full-height container using CSS Flexbox. Show me the exact properties based on the solved-by-flexbox approach.
Prompt 4
Using CSS Flexbox, show me how to build a Holy Grail layout with a header, footer, and three content columns where the side columns are fixed width.
Open on GitHub → Explain another repo

← philipwalton on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.