Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix drag lag in form builder #6121

Closed
timotheeg opened this issue Apr 19, 2023 · 3 comments · Fixed by #6189
Closed

Fix drag lag in form builder #6121

timotheeg opened this issue Apr 19, 2023 · 3 comments · Fixed by #6189
Assignees

Comments

@timotheeg
Copy link
Contributor

No description provided.

@karrui
Copy link
Contributor

karrui commented Apr 20, 2023

Note that if we use virtualisation, search and print will not work properly.

I have some ideas to improve perf of the form builder:

We are currently rendering each field using FieldRowContainer, which is way too heavy. The container should realistically be loaded only when the field is active. We should render something less heavy (display only component, maybe?) when the field is not active. I think this could improve the perf and is worth a try.

@foochifa
Copy link
Contributor

Yep! Thats what we have explored, found a way to react memo the fieldrows and by extracting out some of the hooks to the parent builderfield we were able to avoid most of the re-renders (Though there are still a few unnecessary ones including the updating of the field index for non-edited fields)

@foochifa
Copy link
Contributor

Like this! my intel mac a bit lag when recording

Screen.Recording.2023-04-21.at.11.23.52.AM.mov

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants