Description
When a Bruno project contains thousands of requests (APIs), the application becomes extremely sluggish and UI freezes occur. Opening the application or expanding folders causes severe performance degradation.
However, if the requests are split into multiple separate Bruno projects (by adding \�runo.json\ to subfolders), the performance is normal. This indicates that the performance bottleneck is caused by loading and rendering a massive number of requests in a single project.
Cause
Upon investigating the codebase, it appears that the \Sidebar\ collections list renders the tree recursively (\CollectionItem\ renders its children components directly). When a folder containing thousands of requests is expanded, thousands of DOM nodes are mounted simultaneously without any virtualization.
Proposed Solution
Since
eact-virtuoso\ is already a dependency in \�runo-app, we can optimize the \Sidebar\ by flattening the collections tree and using \Virtuoso\ to render only the visible items (Virtual Scrolling).
I have already implemented a proof-of-concept locally that:
- Flattens the collections tree based on the \collapsed\ state.
- Replaces the recursive rendering in the Sidebar with <Virtuoso>.
This completely eliminates the UI freeze. I would love to submit a PR for this! Should I go ahead and open the PR for review?
Description
When a Bruno project contains thousands of requests (APIs), the application becomes extremely sluggish and UI freezes occur. Opening the application or expanding folders causes severe performance degradation.
However, if the requests are split into multiple separate Bruno projects (by adding \�runo.json\ to subfolders), the performance is normal. This indicates that the performance bottleneck is caused by loading and rendering a massive number of requests in a single project.
Cause
Upon investigating the codebase, it appears that the \Sidebar\ collections list renders the tree recursively (\CollectionItem\ renders its children components directly). When a folder containing thousands of requests is expanded, thousands of DOM nodes are mounted simultaneously without any virtualization.
Proposed Solution
Since
eact-virtuoso\ is already a dependency in \�runo-app, we can optimize the \Sidebar\ by flattening the collections tree and using \Virtuoso\ to render only the visible items (Virtual Scrolling).
I have already implemented a proof-of-concept locally that:
This completely eliminates the UI freeze. I would love to submit a PR for this! Should I go ahead and open the PR for review?