We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hi, something has changed in the latest React release, because the component started to rerender repeatedly.
The problem is line 53 in LinesEllipsis component: https://github.com/xiaody/react-lines-ellipsis/blob/master/src/index.jsx#L53
componentDidUpdate (prevProps) { if (prevProps.winWidth !== this.props.winWidth) { this.copyStyleToCanvas() } if (this.props !== prevProps) { this.reflow(this.props) } }
if I change the comparison of the props to something like this:
if (JSON.stringify(this.props) !== JSON.stringify(prevProps)) { this.reflow(this.props) }
the problem is solved.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hi,
something has changed in the latest React release, because the component started to rerender repeatedly.
The problem is line 53 in LinesEllipsis component:
https://github.com/xiaody/react-lines-ellipsis/blob/master/src/index.jsx#L53
if I change the comparison of the props to something like this:
the problem is solved.
The text was updated successfully, but these errors were encountered: