Skip to content

[8.19] [Lens] Optimize unnecessary re-renders (#220366)#221773

Merged
dej611 merged 4 commits intoelastic:8.19from
dej611:backport/8.19/pr-220366
Jun 3, 2025
Merged

[8.19] [Lens] Optimize unnecessary re-renders (#220366)#221773
dej611 merged 4 commits intoelastic:8.19from
dej611:backport/8.19/pr-220366

Conversation

@dej611
Copy link
Contributor

@dej611 dej611 commented May 28, 2025

Backport

This will backport the following commits from main to 8.19:

Questions ?

Please refer to the Backport tool documentation

## Summary

After a conversation with @markov00 I've ran an investigation of
unwanted re-render due to an abuse of `useEffect`, which can be easily
converted into `useMemo` calls.

(cherry picked from commit d859fc0)

# Conflicts:
#	x-pack/platform/plugins/shared/lens/public/editor_frame_service/editor_frame/editor_frame.test.tsx
@dej611 dej611 requested a review from kibanamachine as a code owner May 28, 2025 12:23
@dej611 dej611 added the backport This PR is a backport of another PR label May 28, 2025
@dej611 dej611 enabled auto-merge (squash) May 28, 2025 12:24
@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
lens 1.5MB 1.5MB -350.0B

@dej611 dej611 merged commit 58d86bc into elastic:8.19 Jun 3, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants