Skip to content

perf(web): virtualize heavy lists, coalesce feed paints, optimize ima… - #1032

Merged
IbrahimIjai merged 1 commit into
SO4-Markets:mainfrom
DeSaint007:feat/931-934-performance
Oct 21, 2026
Merged

IbrahimIjai merged 1 commit into
SO4-Markets:mainfrom
DeSaint007:feat/931-934-performance

Conversation

@DeSaint007

Copy link
Copy Markdown
Contributor

Summary

This PR addresses four assigned frontend performance issues by improving large-list rendering, reducing unnecessary order-book updates, optimizing image assets, and introducing browser performance monitoring.

Changes Implemented

1. Virtualize Large Lists — #931

  • Implemented windowed rendering for large recent-trade histories.
  • Added virtualization to shared data tables used for positions, orders, and funding history.
  • Reduced the number of mounted DOM rows for large datasets.
  • Preserved existing table functionality and accessibility attributes.

2. Optimize Order-Book Rendering — #932

  • Coalesced order-book state updates using requestAnimationFrame to avoid unnecessary renders during high-frequency updates.
  • Added IntersectionObserver visibility detection to suspend off-screen order-book subscriptions.
  • Included cleanup for pending animation frames and subscriptions.

3. Optimize Image Assets — #933

  • Generated optimized WebP versions of application icons.
  • Added WebP alternatives to the application manifest while retaining PNG fallbacks.
  • Generated an optimized Open Graph image and updated its metadata.
  • Reduced individual image asset sizes where possible.

4. Implement Web Vitals Monitoring — #934

  • Introduced browser performance observers for Largest Contentful Paint (LCP), Cumulative Layout Shift (CLS), and Interaction to Next Paint (INP).
  • Integrated measurements with the existing bounded telemetry manager.
  • Added observer cleanup to prevent unnecessary background monitoring.
  • Kept performance telemetry free of wallet identifiers and other personally identifying information.

Testing and Verification

  • Production web build: Passed
  • UI package typecheck: Passed
  • Order-book reconciliation tests: Passed
  • New large-trade virtualization test: Passed
  • Existing recent-trades suite: Contains failures associated with existing overlay and formatting expectations.
  • Repository-wide typecheck: Blocked by a pre-existing syntax error in DepthLadder.test.tsx.

Visual regression screenshots and Lighthouse performance measurements are still outstanding.

Notes

All changes are contained in one commit on a clean branch based on the upstream default branch (main).

The commit was created using the DeSaint007 GitHub identity, with no unrelated inherited commits.

Issues Addressed

Closes #931
Closes #932
Closes #933
Closes #934

@vercel

vercel Bot commented Oct 21, 2026

Copy link
Copy Markdown

@DeSaint007 is attempting to deploy a commit to the Ijai's projects Team on Vercel.

A member of the Team first needs to authorize it.

@drips-wave

drips-wave Bot commented Oct 21, 2026

Copy link
Copy Markdown

@DeSaint007 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@IbrahimIjai
IbrahimIjai merged commit a9ba7fe into SO4-Markets:main Oct 21, 2026
2 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants