patrik-piskay / react-truncate-markup

✂️ React component for truncating JSX markup

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Warning when used in tab

collaboration-tools opened this issue · comments

Great little component - thanks. Your home page does discuss conditional rendering, but any advice on using the component in a TabContainer? Every time a tab not containing the component is selected, the warning below is triggered:

console.warn('ReactTruncateMarkup: number of currently rendered lines: ' + computedLines + ', not truncating...\n It may be caused by target element not being visible at the time of computation.');

I've had to comment it out since in dev it clogs up the console ;-)

Best, Keith

Fixed in v5.1.0