SAMPLE REPORT
See the reasoning behind a frontend recommendation.
A fictional report for Magnificent Invoices. Follow a finding from evidence to proposed action and verification. It contains no client data or measured client results.
FICTIONAL PRODUCT · ILLUSTRATIVE FINDINGS
Magnificent Invoices, a B2B invoicing product.
A Next.js application with TypeScript. Customers open shared document links; staff create, preview and save invoices. Changes to the editor have become difficult to review.
The product, code and examples below are invented. They demonstrate the report format and reasoning; they are not client findings or measured results. Any resemblance to real companies, products or people is purely coincidental.
REPORT CONTENTS
Question: what should change before the next invoice-editor update?
Illustrative scope: shared document links, invoice totals and editor changes. No production system was reviewed.
Suggested order of work: Start with document access and invoice totals (01, 04). Follow with data checks and loading (05, 02), then separate the editor with tests in place (03).
DOCUMENT ACCESS · FIX FIRST
A valid document link shows an empty list.
Example evidence
The link uses the customer's name as a lookup key. Two Unicode spellings of José look identical but do not match. One request returns documents; the other returns HTTP 200 with an empty list.
Jos\u00E9 → documents found
Jose\u0301 → HTTP 200 · []Why it matters
Customers can mistake a failed lookup for missing documents. The screen gives them no way to tell the difference.
Recommended action
Use the stable customer ID supplied by the API in new links. Agree support for existing name-based links with the API owner, and distinguish lookup errors from a genuinely empty list.
How to verify
Both spellings open the same documents. Existing links still work, while an unknown customer produces a clear error.
LOADING · WEEK 2
Opening the list also loads the editor and export tools.
Example evidence
In the example dependency graph, the invoice-list entry imports the editor and PDF export module. Both enter the initial load although neither is used to read the list.
InvoiceList
→ InvoiceEditor
→ PDF exportWhy it matters
Every visit downloads and processes code for actions the user may never take. This adds avoidable work before the list is ready.
Recommended action
Load the editor when editing starts and the existing PDF library when export is requested. Show a loading state, handle failures and allow a retry.
How to verify
A fresh list visit makes no editor or export request. Both actions still work. Compare transferred JavaScript and list readiness under the same device, network and cache conditions.
CHANGE RISK · WEEK 3
The editor couples totals, saving and screen state.
Example evidence
The same component owns line edits, discount rules, saving and preview state. A change to rounding touches both rendering and save preparation; focused checks require mounting the whole editor.
InvoiceEditor
lines + totals + save + previewWhy it matters
A small change crosses several behaviours. Reviewers have to check a wider area, and failures are harder to isolate.
Recommended action
Resolve the rounding mismatch between the editor and preview first. Before restructuring the editor, add tests for the agreed invoice rules and for saving, including failures. Keep the shared calculation in a separate function with unit tests, then move save handling out of the UI component and cover it with integration tests. Limit this change to calculations and saving.
How to verify
Check that regression tests catch known defects and pass after the fixes. A complete user-flow test should create an invoice, edit it, save it and reopen it with the expected values. A failed save should let the user retry without losing edits. These checks must still pass after restructuring and should test what the user sees and can do.
INVOICE CORRECTNESS · FIX FIRST
The editor and preview show different totals.
Example evidence
For three lines of €19.95 with a 10% discount, the editor rounds each discounted line; the preview rounds after adding them. With half-up rounding, the same invoice shows €53.88 and €53.87 before tax.
Editor €53.88
Preview €53.87Why it matters
Staff cannot rely on the displayed total when checking an invoice. One cent exposes a disagreement in the calculation rules.
Recommended action
Agree the rounding rule with the product owner and API owner. Implement one shared calculation for the editor and preview, with explicit decimal handling, and check it against the server result.
How to verify
Tests cover discounts, quantities and rounding boundaries. The editor, preview and server agree on the approved examples.
DATA VALIDATION · WEEK 2
TypeScript passes. An API response still breaks the screen.
Example evidence
The API response is cast to Invoice without checking its shape. When customerName is null, calling trim() throws. A type assertion changes what the compiler assumes; it does not validate the response.
const invoice =
(await response.json()) as Invoice;
invoice.customerName.trim();
// API: { customerName: null }Why it matters
TypeScript types are erased during compilation. A type assertion does not validate an API response at runtime. An unexpected null can therefore prevent the invoice view from rendering even when the build passes.
Recommended action
Validate API responses at runtime, for example with Zod, before using them in the view. Configure lint rules to reject unsafe type assertions and unsafe uses of any. Model nullable fields accurately and show a recoverable error when validation fails.
How to verify
Boundary tests reject invalid data and accept valid invoices. An integration test confirms that a malformed response shows an error with a retry action instead of breaking the page.
ILLUSTRATIVE 30-DAY PLAN
An order of work, with a check at every step.
This is a planning window alongside the team's normal work. The team should estimate effort and confirm capacity before committing to dates; implementation is separate from the audit.
Week 1
Restore reliable links and totals
FINDINGS 01 + 04
Work
Add regression tests for the failing links and totals. Fix customer lookup and agree one rounding rule for the editor, preview and API.
Complete when
Existing links open the expected documents. All three calculation paths agree on the approved cases.
Suggested owner: Frontend, with Product and the API owner
Week 2
Check incoming data and reduce loading
FINDINGS 05 + 02
Work
Validate invoice API responses at runtime, for example with Zod, and test error recovery. Defer editor and export modules; compare loading before and after under matching conditions.
Complete when
Invalid data has a clear recovery path. The list loads less JavaScript, and editing and export still work.
Suggested owner: Frontend, with QA
Week 3
Separate the editor with tests in place
FINDING 03 · AFTER THE TOTALS FIX
Work
With the rounding mismatch fixed, protect the editor's behaviour with tests before changing its structure. Keep the shared calculation separate from the UI and move save handling out of the component. Cover calculations with unit tests and saving with integration tests.
Complete when
Creating, editing, saving and reopening an invoice preserves the expected values. A failed save allows a retry without losing edits. Regression tests still pass after restructuring.
Suggested owner: Frontend, with Product and QA
Week 4
Verify the changes and record what remains
FINDINGS 01–05
Work
Repeat the report's scenarios, review the loading comparison and check error handling. Update each risk with evidence and any remaining work.
Complete when
Each finding is closed, reduced or still open, with a reason, supporting evidence and an owner for the next action.
Suggested owner: Frontend and QA, reviewed with Product
Correct document access and invoice totals first. Establish tests before changing the editor's structure. Any further editor work depends on what this limited extraction reveals.
What your team should be able to decide.
Which risks deserve attention, why they come first, and how to check the result. A real report bases those decisions on your product, evidence and constraints.
See what is included in the auditDiscuss a decision in your frontend.
A few sentences about your product, the concern and any deadline are enough for the first enquiry. We will tell you whether the audit fits and when we could start.
Request audit availability