Closed aribronstein closed 6 years ago
I'm getting a large number of [Violation] 'requestIdleCallback' handler took [x]ms when scrolling up and down my page in chrome once I have activated my sticky element.
mock code
class CartItem extends React.Component { constructor(props) { super(props); } render() { return ( <StickyContainer key={this.props.item.item_id} ref={(ref) => this.item_ref = ref} className={this.props.item.isRemoving ? styles.item_removing : styles.item} onTransitionEnd={this.transitionEnd}> <Sticky> {({style}) => { return ( <div className={styles.table} style={ this.state.toggleAlternatives ? style: {} }> ..... </div> ) }} </Sticky> ..... </StickyContainer> ); } };
I'm getting a large number of [Violation] 'requestIdleCallback' handler took [x]ms when scrolling up and down my page in chrome once I have activated my sticky element.
mock code