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

prevent rerender on scroll.. #407

Open
Pleizz opened this issue Mar 26, 2023 · 1 comment
Open

prevent rerender on scroll.. #407

Pleizz opened this issue Mar 26, 2023 · 1 comment
Labels
question Further information is requested

Comments

@Pleizz
Copy link

Pleizz commented Mar 26, 2023

react-fullpage calls render function with event like onLeave, afterLoad events..
that leads too many rerenders..

so.. i've developed to render empty div if component's index isn't current index.

but not resolved since it calls twice per scroll (onLeave, afterLoad) and result in render hundreads of empty components twice..

is there any way to reduce rerender number of times?
i render about hundreads of elements with memoization..

sincerely..

@alvarotrigo
Copy link
Owner

What is exactly the problem you face with the re-renders?

When scrolling up/down on the example I can't see any re-writes on the DOM except the necessary ones with the state classes.

@alvarotrigo alvarotrigo added the question Further information is requested label Mar 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants