Skip to content

    Frontend System Design

    How to Read and Reproduce a Front-End Case Study

    Learn the ten-part rubric every front-end case study follows, how to tell sourced facts from design choices and illustrative numbers, and how to reproduce one.

    By Published 13 min read

    • frontend-system-design
    • case-study
    • rubric
    • design-review
    Share

    Standard lessonbeginnerFrontend System Design

    Before this: A Repeatable Framework for Front-End Design Problems

    What you'll learn: By the end of this lesson you will be able to explain what an "educational reference design" is, name the ten parts every front-end case study in this course follows, label any statement as a sourced fact, a design decision or an illustrative number, score a case against the rubric, and reproduce a case with a small lab.

    Imagine two ways to learn chess. In one, someone tells you who won a famous game. In the other, someone replays it move by move, shows the position before each move, says what the alternatives were, and hands you the board so you can try the other move. The second is how you improve. A front-end case study is meant to be the second kind: a game you can replay, not a result you take on trust.

    That is why this course does not write "how Company X built its feed". Nobody outside a company can verify its internals, and a confident description of them is a story, not evidence. The case studies in module F23 are reference designs: a design for a well-known kind of product, built from public standards and documentation, with every number labelled and every decision explained.

    The core idea

    Three statements carry the whole method.

    1. A case is a reference design, not a report. It shows one reasonable way to build a kind of product, with its reasoning. It does not claim to describe what any real company runs.
    2. Every case has the same ten parts. A fixed shape lets you compare cases, notice what one leaves out, and reuse the shape for your own design documents.
    3. Every statement carries a label. It is a sourced fact (a standard or official page says so), a design decision (a choice with alternatives and a cost), or an illustrative number (made up to make arithmetic concrete, and said to be).

    What "educational reference design" means

    A case about a product a named company is known for opens with this sentence, with the name filled in: This is an educational reference design, not the verified internal architecture of [company]. A case about a generic product (a search box, a feed, a chat window) names no company, and the course prefers that. The rules behind the sentence are short.

    • No invented company facts. A case never says a named company uses a particular library or number unless a public document does, and then it links the document.
    • Designs come from public material: web standards, official documentation of the tools named, and this course's other lessons.
    • Numbers are labelled. Anything not taken from a source is marked illustrative. It is a placeholder, and the reader is told to replace it.
    • Scenarios are not histories. Every "In practice" section says it is "a realistic scenario, not a case history".

    Three kinds of statement

    • Sourced fact: a claim a standard or official page supports, with a link. Follow the link, and trust it as far as the source goes.
    • Design decision: a choice among alternatives, with its cost. Compare it with your constraints. Example: wait for a pause in typing before sending a request, which delays every suggestion by that pause.
    • Illustrative number: a figure chosen to make an example concrete, such as a 150 ms pause. Replace it with a measurement.

    One sentence can hold two labels, and a good case separates them. MDN says a fetch() promise does not reject when the server answers 404 or 504, so code must check Response.ok: a sourced fact. "Set aria-expanded on the input" is a sourced fact: the Authoring Practices Guide says the combobox sets it to false when the popup is hidden and true when it is visible. "Close the popup on blur" is a decision the case must justify.

    The ten parts of every case

    The ten parts extend the seven passes of A Repeatable Framework for Front-End Design Problems with two things a case needs: an architecture figure up front, and a way to prove the design.

    Figure 1. The ten parts, in order

    flowchart LR accTitle: The ten parts of a front-end case study accDescr: Ten parts in order: frame, requirements, targets, architecture, data and state, interface, delivery, failure, decisions, and prove and present. Dotted arrows return from targets to requirements and from failure to interface. A["1 Frame"] --> B["2 Requirements"] B --> C["3 Targets"] C --> D["4 Architecture"] D --> E["5 Data and state"] E --> F["6 Interface"] F --> G["7 Delivery"] G --> H["8 Failure"] H --> I["9 Decisions"] I --> J["10 Prove and present"] C -.->|"a number cuts scope"| B H -.->|"a missing state"| F

    How to read this: the solid arrows are the order of the sections. The dotted arrows are the two loops that happen most often: a target that forces you to cut a requirement, and a failure that adds a state to the interface.

    Part The question It must contain
    1. Frame What is built, for whom, and what kind of claim is this? The reference-design sentence, the user, a one-paragraph description
    2. Requirements What must it do, and what is out? Functional and non-functional requirements, an out-of-scope list
    3. Targets What does "good" mean, in numbers? Targets labelled illustrative, or taken from a named source
    4. Architecture Which parts exist, and where are the boundaries? An architecture figure and a sentence per box
    5. Data and state What data exists, who owns it, how fresh, where does it live? A table of data, owner, freshness and location
    6. Interface What states does the screen have, and how is it operated? A state diagram; keyboard and screen-reader behaviour
    7. Delivery Where does code run, what ships, what is cached? Loading and caching choices; budgets
    8. Failure What breaks, and what does the person see? A failure list with a response for each
    9. Decisions What was chosen, at what cost, when revisited? Options, choice, cost, revisit trigger
    10. Prove and present How is it checked, and how is it explained in 45 minutes? A lab or a statement that there is none; exercises; interview questions

    Parts 1 and 10 matter most for trust. Part 1 sets the kind of claim, and part 10 is where claims become checkable, because a lab that prints deterministic output is evidence that prose can only describe.

    How a case gets made

    Figure 2. From sources to a reproduction

    Public sources and requirements feed a reference design; a lab with captured output backs the lesson pagePublic sources to Reference design (facts); Requirements to Reference design (constraints); Reference design to Lab (implement); Lab to Captured output (capture); Captured output to Lesson page (embed); Lesson page to Your reproduction (read)EVIDENCE YOU CAN RERUNPublic sources: specs, official docsPublic sourcesspecs, officialdocsRequirements: scope, out of scopeRequirementsscope, out ofscopeReference design: ten partsReferencedesignten partsLab: pure core, testsLabpure core, testsCaptured output: from a real runCapturedoutputfrom a real runLesson page: text and figuresLesson pagetext and figuresYour reproduction: read, then rerunYourreproductionread, then rerunfactsconstraintsimplementcaptureembedread

    How to read this: facts and constraints go into the design. The design is implemented as a small lab, and the lab's real output is captured and embedded in the page byte for byte, so you can rerun the lab and compare.

    Two rules protect the lab path. Output shown in a lesson is copied from a captured run and never typed by hand.

    Reproducing a case: the pure-core pattern

    The labs follow one pattern so that a reader gets the same output on any machine. The logic is a pure core: plain TypeScript with no DOM, whose clock and network are injected. A fake backend answers after a delay the test chooses, so slow and out-of-order answers can be reproduced on demand. A virtual clock moves only when a test says so. The user interface is thin: it renders the core's state and forwards events.

    Figure 3. The structure every lab uses

    Tests and a thin view drive a pure core whose clock and backend are injectedThin view to Pure core (events); Tests to Pure core (drive); Pure core to Virtual clock (timers); Pure core to Fake backend (requests)PURE TYPESCRIPT, RUNS IN NODETests: vitestTestsvitestThin view: renders stateThin viewrenders statePure core: state and rulesPure corestate and rulesVirtual clock: moves on commandVirtual clockmoves on commandFake backend: chosen delaysFake backendchosen delayseventsdrivetimersrequests

    How to read this: tests and the view talk to the core through the same few functions. The core reaches the outside world only through the clock and backend it was given, so a test can replace both.

    One limit to say plainly: the React tests in these labs run in jsdom, a JavaScript model of the DOM. It is not a browser, does no layout or painting, and no screen reader reads it. A lab can show that roles, attributes and focus are set correctly. It cannot show how a page looks or what an assistive technology says, and a case never claims either.

    Three illustrations

    A minimal example: a "like" button through the rubric

    Fill each part with one line. The point is the shape, not the depth.

    Part One line for a like button
    1. Frame A person likes a post; reference design, no company named
    2. Requirements Toggle on and off, count visible; out of scope: reactions, analytics
    3. Targets The count changes within one frame of the click (illustrative)
    4. Architecture Button, a small store, a PUT and DELETE endpoint
    5. Data and state Liked flag and count, owned by the server, shown optimistically
    6. Interface Pressed and not-pressed states exposed to assistive technology; works from the keyboard
    7. Delivery Tiny code; works as a form post without scripts
    8. Failure Request fails: revert and say so; two rapid clicks: the last intent wins
    9. Decisions Optimistic update; cost: a revert path to test
    10. Prove A test with a fake server that rejects the first call

    A realistic example: the search-autocomplete case

    The next lesson in the module, the search autocomplete case, is a store search box that suggests items as the shopper types. It names no company; its targets are all labelled illustrative; its interface part covers the combobox keyboard model and a polite status message; its failure part covers late answers, failed requests and text composed with an input method editor; and its proof is a lab with a pure core, a React layer, a fake backend and tests. Every other case in the module (a feed, a chat window, an email client, a collaborative editor, a storefront) fills the same slots with different content.

    A failure example: the confident number

    A case says "suggestions arrive in 120 ms at the 95th percentile". A reader copies it into a design document as a target. Nobody measured it; the word "illustrative" was lost in an edit. Months later the team argues about whether the system "meets its target" and nobody can say what the number meant. The rubric guards against this twice: part 3 requires every figure to be labelled, and the review step below requires each number to carry a source or the word illustrative. The corrected sentence reads "Assume suggestions take 120 ms at the 95th percentile (illustrative; replace with a measurement)". It is longer, and it cannot be mistaken for a finding.

    Scoring a case: the rubric as a review

    Score each part: 0 if it is absent, 1 if it is mentioned without an artifact (a table, figure or list), 2 if it has an artifact, its reasoning and its cost. The maximum is 20. A score below 2 on parts 8 and 9 is the usual warning sign, because failure and trade-offs are what a sales-style description omits. A second check goes statement by statement.

    Figure 4. Labelling one statement

    flowchart TD accTitle: Deciding how to label a statement in a case accDescr: For each statement ask whether a source supports it. If yes, link the source and call it a sourced fact. If not, ask whether it is a choice, in which case give alternatives and cost, or a number, in which case label it illustrative. Otherwise remove it. S["A statement in the case"] --> Q1{"Does a source you
    read support it?"} Q1 -->|"yes"| F["Sourced fact: link the source"] Q1 -->|"no"| Q2{"Is it a choice?"} Q2 -->|"yes"| D["Design decision:
    name alternatives and cost"] Q2 -->|"no"| Q3{"Is it a number?"} Q3 -->|"yes"| N["Label it illustrative
    or measure it"] Q3 -->|"no"| R["Remove it"]

    How to read this: a statement has a source, is a choice you can argue with, is a number you must label, or has no business in the case. There is no fifth category called "common knowledge".

    Try it on ten statements a search-box case might make.

    Statement Label Basis
    Calling abort() on an AbortController can cancel a fetch() request Sourced fact MDN: abort() is able to abort fetch requests, response-body consumption and streams
    Without an argument, the signal's reason is an AbortError DOMException Sourced fact MDN: AbortSignal.reason
    max-age=N keeps a response fresh until N seconds after it was generated Sourced fact MDN: Cache-Control
    private lets only a private cache, such as a browser cache, store a response Sourced fact MDN: Cache-Control
    An element with role="status" is a polite live region Sourced fact MDN: the status role has an implicit aria-live of polite
    A results count that does not take focus is a status message under WCAG 4.1.3 (Level AA) Sourced fact W3C: Understanding 4.1.3
    DOM focus stays on the input; aria-activedescendant names the active option Sourced fact Authoring Practices: combobox
    Escape dismisses the popup if it is visible Sourced fact Authoring Practices: combobox
    Pause 150 ms before a request Illustrative number Replace with a measurement
    Keep the last 50 answers in memory Design decision Needs its cost: memory use and stale entries
    Choice in the format Benefit Cost
    Fixed ten parts Cases compare; gaps show Small problems feel padded
    Generic design, no company No false claims about real systems Less glamour
    Labelled illustrative numbers Honest, easy to replace Readers wanting a real figure get none

    Presenting a case in 45 minutes

    The ten parts also give you the shape of an interview or design review. An illustrative split, to adapt: five minutes to clarify the problem and scope, five for targets, ten for architecture and data, ten for interface and delivery, five for failure, five for decisions, five for questions. Say each number's label aloud: "I will assume, as an illustrative figure, that the pause is 150 ms; I would measure it."

    In practice: a team writes its first design doc from a case

    The situation

    A team of six front-end engineers must add a global search box to an internal operations dashboard in two weeks. A teammate finds a case study and proposes copying its design.

    Starting architecture

    • A search input in the page header with a client store behind it.
    • An existing HTTP endpoint that returns matching items for a query.
    • No cache, no cancellation, and no keyboard behaviour beyond "it should work with the keyboard".

    Options considered

    1. Copy the case's numbers and structure into a design document.
    2. Use the ten parts as headings, fill each from the team's own constraints, and treat the case's decisions as options to argue with.
    3. Skip the document and build, since the box is small.

    The decision

    Option 2. The team lists its own users, devices and endpoint behaviour under parts 1 to 3, marks every number in part 3 as measured or assumed, and uses the case only for parts 4 to 9 as a starting list of decisions. The decision table has a "revisit when" column for each choice.

    Rollout and verification

    The team writes the lab-style test first: a fake endpoint with chosen delays and failures, and a virtual clock. It checks that a late answer for an old query is never shown, that a failed request leaves the typed text alone, and that the box works from the keyboard alone. It then replaces each assumed number with a measured one.

    The 2 a.m. failure

    The endpoint's latency doubles after a deployment by another team. Because part 8 lists "slow answer" and part 3 recorded the assumed latency, the on-call engineer sees at once that an assumption, not the code, has been violated. The fix is a change to the pause and a note to the other team. Had the case's figures been copied as facts, nobody would have known which number was now wrong.

    This is a realistic scenario, not a case history.

    Architect's notes

    • Use the ten parts as a template for your own design documents. A short document with all ten beats a long one that skips failure and decisions.
    • Keep "illustrative" inside the sentence, not in a footnote, so it travels when someone copies the line.

    Common mistakes

    • Copying numbers without their labels. An illustrative figure becomes a requirement within a quarter.
    • Treating a reference design as a company's architecture. The format exists so nobody has to believe that.
    • Skipping part 8. Happy-path designs look complete until the first slow response.
    • Claiming what a lab cannot show. A jsdom test does not show layout, phone speed or screen-reader speech; name those as untested.

    Key takeaways

    • A front-end case study here is an educational reference design: replayable, sourced and labelled, not a report on a company.
    • Every case has ten parts, from frame to prove and present.
    • Every statement is a sourced fact, a design decision or an illustrative number; anything else is removed.
    • Labs use a pure core with an injected clock and a fake backend, so a reader can rerun them and get the same output.
    • Score each part 0 to 2; low scores on failure and decisions are the common weakness.

    Practice exercises

    Exercise 1: Beginner (30 minutes). Pick a small feature you know, such as a "copy link" button, and fill all ten parts with one line each. Mark the part you had not thought about before.

    Exercise 2: Intermediate (1 hour). Take a blog post that describes how a product was built and label ten of its statements. How many were unsupported?

    Exercise 3: Advanced (2 hours). Write a one-page design document for a feature at your work using the ten headings. In part 3 write each number as measured or assumed, and in part 9 add a revisit trigger to each decision.

    Official documentation

    In this course

    Ask about this article

    Get answers grounded in this post. AI-generated — based on this article, and may be imperfect.

    Scaled AI Weekly

    Enjoyed this? Get more like it every Monday.

    Real architecture decisions, LLMOps patterns that survive production, and engineering leadership advice — from 12+ years of building at enterprise scale. Free. No spam. Unsubscribe anytime.

    Get new articles by email

    Free. We email a confirmation link first, and you can unsubscribe from any email.

    Join engineers building production AI systems

    Comments