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

Really fast effect after scroll up/down #6

Open
lps83 opened this issue Apr 6, 2020 · 7 comments
Open

Really fast effect after scroll up/down #6

lps83 opened this issue Apr 6, 2020 · 7 comments

Comments

@lps83
Copy link

lps83 commented Apr 6, 2020

Same effect x100 on a one page

@adrianodesenv
Copy link

I have the same trouble. Can someone help me?

@lps83
Copy link
Author

lps83 commented Apr 18, 2020

I fixed it ! I made my own lib ^^

@gabrielpetersson
Copy link

Same here, if I use onScroll and setState

@gabrielpetersson
Copy link

As long as you do not setState in a parent or in the same component it seems to work

@LamelDev
Copy link

@lps83 Can you share it? :D

@whoami-shubham
Copy link

whoami-shubham commented Jul 31, 2020

I solved this problem by using React.memo, here is a sample code if anyone need

const TypingAnimation =  React.memo(()=>{
  return <Typical
  loop={Infinity}
  wrapper="p"
  steps={
    [
      'Hello',
      1200,
      'World',
      1200,
     
    ]
  }
 />
},(props,prevProp)=> true ); // this line prevent re rendering

@JohnBerd
Copy link

Thanks @whoami-shubham it made the trick!

This was referenced Oct 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants