ktmud commented on code in PR #21488:
URL: https://github.com/apache/superset/pull/21488#discussion_r972497853
##########
superset-frontend/src/components/Chart/Chart.jsx:
##########
@@ -299,22 +314,24 @@ class Chart extends React.PureComponent {
onError={this.handleRenderContainerFailure}
showMessage={false}
>
- <Styles
- data-ui-anchor="chart"
- className="chart-container"
- data-test="chart-container"
- height={height}
- width={width}
- >
- <div className="slice_container" data-test="slice-container">
- <ChartRenderer
- {...this.props}
- source={this.props.dashboardId ? 'dashboard' : 'explore'}
- data-test={this.props.vizType}
- />
- </div>
- {isLoading && !isDeactivatedViz && <Loading />}
- </Styles>
+ <InView triggerOnce onChange={this.handleChartInView}>
Review Comment:
Can we add a
[`rootMargin`](https://github.com/researchgate/react-intersection-observer#options)
to page bottom so charts near the bottom but below the fold can load faster
(so users can see less loading states)?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]