Skip to content

perf(ui): lazy-load routes and Azure Maps assets [5/5] - #189

Open
Anthony Cintron (prbatero) wants to merge 4 commits into
prbatero/feat/perf-project-details-uifrom
prbatero/feat/perf-ui-route-loading
Open

perf(ui): lazy-load routes and Azure Maps assets [5/5]#189
Anthony Cintron (prbatero) wants to merge 4 commits into
prbatero/feat/perf-project-details-uifrom
prbatero/feat/perf-ui-route-loading

Conversation

@prbatero

Copy link
Copy Markdown
Contributor

Summary

Part 5 of 5 in the project layer-loading performance stack. Remove unrelated map and route startup work from the project page and record final end-to-end measurements.

Changes

  • Code-split application pages with route-level lazy loading.
  • Load Azure Maps control, drawing, styles, and swipe support only before map-dependent routes mount.
  • Remove blocking global Azure Maps tags from index.html.
  • Expand browser timing diagnostics and correct request-start accounting.
  • Reconcile the feature specification with tested cache, transaction, concurrency, and performance semantics.

Testing

  • Full hastelib suite: 581 passed.
  • Performance-stack API suite: 50 passed; two independent security cases are owned by fix(api): reject client-supplied workflow state #184.
  • Queue suite: 6 passed.
  • UI suite: 121 passed.
  • New UI utilities: 100% line, branch, and function coverage.
  • Changed UI files pass ESLint with zero warnings; production Vite build passed.
  • Black, isort, flake8, and detect-secrets passed across the stack.

Measurements

  • 50×5 fixture: 603 → 7 logical data-layer calls.
  • Uncached API: 1.85 s p50 / 2.00 s p95.
  • Fresh process cache: 9.1 ms p50 / 12.2 ms p95 with zero logical calls.
  • Production project page: 2.12 s TTI, one initial request, 58 ms post-response render.
  • Terminal project: zero polls during a 26-second window; active project: one non-overlapping conditional poll returning 304.
  • Main JS chunk: 1.49 MB → about 120 KB.

Stack

Review Notes

The seven-call metric counts logical data-layer operations, not Azure REST transactions. Blob downloads remain proportional to records returned. The <1.5 s uncached API and <2 s TTI targets remain open.

Split route modules, load Azure Maps control and drawing assets only before map-dependent screens mount, expand browser timing diagnostics, and reconcile the performance specification with measured uncached, cached, and UI results.
@prbatero
Anthony Cintron (prbatero) requested a review from a team as a code owner September 1, 2026 17:39
Comment thread ui/src/util/azureMapsLoader.test.js Fixed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants