What you'll learn: By the end of this lesson you will be able to build a capstone in slices that stay in step with its design doc, collect four kinds of audit evidence (lab measurement, field data, accessibility checks, tests), score a checklist so that missing evidence never counts as a pass and one failing blocker cannot be hidden by a high score, and run a review that ends in findings with owners and a recorded result.
A house is built by the builder and checked by an inspector. The inspector does not ask whether the builder feels good about it. They bring a list, measure what the list names, and write "not inspected" next to anything they could not reach. A "not inspected" line is not a pass, and a clean report with five such lines is not a clean report.
The capstone follows the same split. The design doc (the previous lesson in this module, named here as plain text because it is written in the same round) holds the plan and the audit plan. This lesson covers the other half: building to the plan, collecting evidence and reviewing the result.
Sources: web.dev Web Vitals and performance budgets, Chrome for Developers on Lighthouse performance scoring, the WCAG-EM methodology, WCAG 2.2 conformance, and W3C guidance on accessibility evaluation tools. All read on 2026-12-02. The lab is a model that scores numbers you type in; it ran no Lighthouse, browser or screen reader.
The core idea
An audit judges evidence against a plan written before the build. A check with no evidence is not a pass, and a blocker that fails stops the release whatever the average says.
Three illustrations run through the lesson:
- Minimal example: one threshold check and what its three outcomes mean.
- Realistic example: an order dashboard (a grocery-marketplace staff tool, an illustrative example) audited twice, before and after a round of fixes.
- Failure example: an audit whose score is high while a blocker fails, and one whose blocker was never measured.
Build: stay close to the doc
Build in thin vertical slices: one screen, from the network call to the keyboard path, before the next screen. Each slice is judged against section 7 of the doc as soon as it exists, so a missed goal is found while it is cheap.
Three habits keep the build and the doc together:
- A change that breaks a decision updates the record. The decision record format (title, context, decision, status, consequences, as Michael Nygard describes it) has a status for this: the old record stays, marked superseded, and a new one is written.
- The budget is enforced in the build, not remembered. web.dev says budgets can be added to the build process with tools such as Lighthouse CI, and that when a threshold is exceeded you either optimize or remove something, or decline to add the new thing. See performance budgets and profiling and CI/CD for front ends.
- Every screen has its states (loading, empty, error, refresh failed) before it counts as done. The error, loading and empty states lesson gives the model, and the testing pyramid and trophy lesson helps decide which tests cover them.
Audit: four kinds of evidence
Figure 1. From build to verdict
How to read this: four kinds of evidence feed one checklist, and a person reads the report. The accent box is the part the lab below models; the other boxes are what produces the numbers it scores.
Lab measurement. A lab run gives repeatable numbers for one build on one setup. The Lighthouse performance score is a weighted average of metric scores, and only metrics contribute to it, not the opportunities and diagnostics it lists. Its documentation also says a lot of the variability between runs is not due to Lighthouse: changing ads or A/B tests, network routing, device differences, browser extensions and antivirus software all move the numbers. So a lab number is a sample, and the audit should say how it was taken.
Field data. web.dev says a good threshold to measure is the 75th percentile of page loads, segmented across mobile and desktop, and gives "good" values: LCP within 2.5 seconds, INP of 200 milliseconds or less, CLS of 0.1 or less. A capstone with no real users has no field data. Say so, and mark those checks as not measured; do not substitute a lab number and call it field. See Core Web Vitals and real user monitoring.
Accessibility. The W3C's WCAG-EM method has five steps: define the scope, explore the target, select a representative sample, evaluate it, report. For a capstone small enough to check every page, check every page. The W3C also says that tools "can not determine accessibility, they can only assist", so the evidence includes a manual keyboard walk of each key flow. WCAG 2.2 conformance applies to full pages and complete processes: every page in a multi-step flow must meet the claimed level. See accessibility fundamentals and WCAG.
Tests. The count of failing tests, and which flows have an end-to-end test. Passing tests show only that what was tested works.
Illustration 1: the minimal example
One check, "INP at the 75th percentile", with the limit from the doc:
| Evidence | Outcome | Meaning |
|---|---|---|
| 172 ms | pass | Inside the limit by more than 10 percent |
| 195 ms | warn | Inside the limit, within the last 10 percent (this lab's own rule) |
| 240 ms | fail | Over the limit of 200 ms |
| (nothing measured) | no-evidence | Unknown. Not a pass |
The fourth row is the one that matters. A missing measurement is information about the audit, not about the product.
The scoring model
The lab for this lesson, examples/frontend/labs/capstone-audit-model, is a small model of such a checklist. It is a model, not a tool: it runs no Lighthouse and no browser, and every number is typed in. The sample data is hand-written and illustrative.
Its rules, all documented in the code:
- 13 checks in five areas (performance, accessibility, resilience, testing, documentation), each tagged blocker, major or minor.
- Four statuses.
pass,warn(within 10 percent of a limit),failandno-evidence. The three Core Web Vitals limits are the published "good" values; every other limit (170 KB of JavaScript, 25 passing tests, 3 decision records) is an illustrative choice. - Points. Pass 1, warn 0.5, fail 0 and no-evidence 0. Weights: blocker 3, major 2, minor 1. An area score and the overall score are weighted percentages.
- Verdict. A blocker that fails, or has no evidence, makes the verdict
blockedwhatever the score. Otherwise 85 or more isready; below that,needs-work.
Figure 2. How the verdict is reached
or unmeasured?"} B -- yes --> X["Verdict: blocked"] B -- no --> S{"Weighted score
85 or more?"} S -- yes --> R["Verdict: ready"] S -- no --> N["Verdict: needs work"]
How to read this: the blocker question comes before the score. A score can be raised by many small passes, so it cannot be allowed to overrule one serious failure.
The code stays pure: audit(evidence) returns results, area scores, the list of unmeasured checks and the verdict. The React part is thin: a status line (role="status"), filter buttons with aria-pressed, a table with row headers, and four number inputs where an empty box removes the measure and does not mean zero. The tests render it in jsdom, which is not a browser: they read roles, names and text, and nothing was seen on a screen.
Build it
The lab is in examples/frontend/labs/capstone-audit-model. It ran with Node 26.13.1, Vitest 5.1.0, React 19.3.1 and TypeScript 7.0.2: 34 tests in two files passed and the type check was clean.
cd examples/frontend/labs/capstone-audit-model
../../node_modules/.bin/vitest run
node src/demo.ts
Illustration 2: the realistic example
The demo audits the same imaginary order dashboard twice. Run 1 is a first attempt. These are the accessibility, resilience, testing and documentation parts of its report and the verdict:
Expected output, captured from a real run (the first attempt, from the accessibility area to the verdict):
accessibility (0/100)
fail blocker Automated accessibility violations: 3 violations reported
fail major Pages in scope that were checked: 4 of 6 pages in scope checked
fail blocker Key user flows completed by keyboard alone: 2 of 3 flows completed
resilience (0/100)
fail major Screen states designed and shown: 5 of 6 states covered
fail major Listed failure modes that were injected: 1 of 4 failure modes injected
testing (100/100)
pass blocker Failing tests: 0 failing
pass minor Passing tests: 31 passing, at least 25 wanted
documentation (0/100)
fail minor Decision records written: 2 records, at least 3 wanted
no-evidence minor Non-goals written down: not measured: nonGoalsListed
overall 27/100, unmeasured: non-goals
verdict: Blocked: inp, a11y-automated, a11y-keyboard
Three blockers fail (INP in the performance area, automated accessibility violations and the keyboard flow). The testing area scores 100 and still the verdict is blocked, because green tests say nothing about a keyboard path. The last documentation check has no evidence: it is listed, scored zero and not hidden.
After one round of fixes, the demo compares the two runs.
Expected output, captured from a real run (the comparison and the blocker experiments, to the end of the file):
=== 3. What changed between the runs
lcp warn -> pass
inp fail -> pass
js-budget fail -> pass
a11y-automated fail -> pass
a11y-coverage fail -> pass
a11y-keyboard fail -> pass
states fail -> pass
failure-injection fail -> pass
adrs fail -> pass
non-goals no-evidence -> pass
=== 4. A high score does not hide a blocker
overall 89/100, verdict: blocked (tests-failing)
overall 89/100, verdict: blocked (inp)
The second run reaches a ready verdict with a full score (the test suite asserts it). These numbers come from the sample data, not from a measurement of any site.
Illustration 3: a failure
The last two lines are the failure example. One failing test, or one unmeasured INP, takes the overall score to 89, above the 85 line, and the verdict is still blocked. Without the blocker rule, a reviewer who read only the score would see a number above the line.
Break it. In runChecks, make a check with missing measures return pass. Two tests fail ("is reported as no-evidence, never as pass" and "an unmeasured blocker blocks too"). The README lists a second experiment. Restore the code afterwards.
Review: a second person reads the evidence
An audit produces a report; a review decides what to do with it. The reviewer is not the author, and reads in this order:
- The design doc's goals and non-goals, to know what the build promised.
- The audit plan (section 7) and the report: does every goal have a row, and does every row have evidence?
- The
no-evidenceandwarnrows first, because they are where an audit is thinnest. - The blockers, then the scores.
- A manual spot check: use the keyboard path on a key flow yourself.
Figure 3. One review round
How to read this: the loop ends in the doc, not in a chat. Only the checks that changed are rerun, and the result, including anything accepted instead of fixed, is written where the next reader will look.
A finding says what is wrong, where, which goal it breaks and what would close it. "Accessibility needs work" is not a finding; "the Mark as packed button is not reachable by Tab on the order detail page (goal G2)" is.
Trade-offs
| Choice | Gain | Cost |
|---|---|---|
| Scored checklist | Repeatable, comparable between runs | A score can look more exact than the inputs deserve |
| Blocker rule before the score | One serious failure cannot hide | Strict: a single blocker stops the release |
| Counting no-evidence as zero | Honest about gaps | A new project looks bad until it measures |
| Lab numbers only | Fast, repeatable | Not what users experience; varies between runs |
| Sampling pages | Less work | A site-wide claim cannot be made from a sample |
| Author-run audit | Quick | No independent eye |
In practice: auditing the order dashboard
This is a realistic scenario, not a case history. It is a composite built from common team practice. It describes no specific company or product, and every number in it is an illustrative assumption.
The situation
The dashboard team has a green CI build and a Lighthouse screenshot in the pull request, and wants to call the capstone done on Friday. Nobody has walked the keyboard paths, field data does not exist yet, and one measure (non-goals written down) was never checked.
Starting architecture
Figure 4. Before the audit
How to read this: the warning boxes mark where evidence is thin: one run on one page stands in for the plan, and nothing is reviewed.
Options considered
| Option | Fixes | Costs | Risk |
|---|---|---|---|
| Ship on the screenshot | No delay | Nothing new learned | Unchecked blockers |
| Audit against the plan, author only | Evidence per goal | A day | No independent eye |
| Audit plus second-person review | Evidence and a fresh read | A day and a reviewer | Review comments to resolve |
The decision
| Field | Decision record |
|---|---|
| Context | One screenshot is the only evidence; keyboard paths and field data are unchecked. |
| Decision | Fill in the evidence for every audit-plan row, score it with the checklist, and have a second person review. Mark what cannot be measured as no-evidence. |
| Consequences, good | Blockers are found before release; gaps are visible. |
| Consequences, bad | The first audit is blocked; Friday moves. |
| Revisit when | Real users exist and field data can replace the lab numbers. |
Rollout and verification
- Fill the evidence file from the audit plan; leave unmeasured values empty, never zero.
- Run the checklist; read the
no-evidencerows first. - Fix the blockers, rerun only the changed checks and compare the two reports.
- The reviewer repeats one keyboard flow by hand, then writes the result into section 9 of the doc.
The 2 a.m. failure
After release, an alert shows INP worse than in the lab, on phones. The audit passed because INP was measured in the lab on a desktop and the field check was marked "not applicable" instead of "no evidence".
First three checks: (1) look at which evidence the INP row used and on what device; (2) compare the field percentile for mobile and desktop; (3) check whether the plan said the metric would be measured in the field. Mitigation: roll back the last change to the heaviest handler. Follow-up: the checklist treats "not applicable" for a blocker as no evidence unless the doc says why.
Architect's notes
- Measure first, then average. Blockers before scores, always.
- Never let a gap look like a pass. The cheapest honesty in an audit is a
no-evidencerow. - Say how each number was taken: lab or field, which page, which device, how many runs.
- Keep the scoring rule in the doc so a different reviewer reaches the same verdict.
- A score is a summary. The review reads the rows.
Common mistakes
- Treating a missing measure as zero or as a pass.
- One Lighthouse run as the whole performance evidence, when runs vary.
- Tool-only accessibility checks with no keyboard walk.
- Claiming conformance for pages not checked.
- Review by the author alone.
- Findings with no owner or no goal attached.
- Moving the threshold after seeing the result.
Key takeaways
- The audit judges evidence against a plan written before the build.
- Four evidence kinds: lab, field, accessibility (tool and manual) and tests.
- Missing evidence is
no-evidence, scored zero and listed, never a pass. - A failing or unmeasured blocker blocks the release whatever the score is.
- Lighthouse scores vary between runs and cover metrics only; tools only assist accessibility evaluation.
- A review ends in findings with owners and a result written into the doc.
Practice exercises
Exercise 1: Starter (30 min). Run the lab's tests and demo. Change one measure in src/sample.ts so that a pass becomes a warn, and predict the new overall score before you run it.
Exercise 2: Intermediate (2 hours). Add a check to src/audit.ts for a second Web Vitals metric of your choice, with a test for each of its four statuses.
Exercise 3: Advanced (half day). Audit your own capstone with the model: fill in the evidence, leave out what you did not measure, and write the findings for your reviewer.
Related reading
In this course:
- Performance Budgets and Profiling: setting and enforcing limits.
- Core Web Vitals: the three metrics and their thresholds.
- Accessibility Fundamentals and WCAG: conformance levels and requirements.
- Testing Pyramid and Trophy: which tests give which evidence.
- Real User Monitoring: field data.
- Backend capstone: design doc, load test and failure injection: the server-side counterpart.
Official documentation
- web.dev: Web Vitals: thresholds and the 75th percentile.
- web.dev: Performance budgets 101: budgets and enforcing them.
- Chrome for Developers: Lighthouse performance scoring: how the score is built and why it varies.
- W3C: WCAG-EM: evaluation steps, sampling and reporting.
- W3C: Understanding Conformance: levels and conformance requirements.
- W3C WAI: Selecting web accessibility evaluation tools: what tools can and cannot do.