You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2020/10/20 04:33:00 UTC

[GitHub] [incubator-superset] rusackas commented on a change in pull request #11239: refactor: Replace usages of reactable in TimeTable

rusackas commented on a change in pull request #11239:
URL: https://github.com/apache/incubator-superset/pull/11239#discussion_r508203070



##########
File path: superset-frontend/src/visualizations/TimeTable/TimeTable.jsx
##########
@@ -89,7 +90,74 @@ const defaultProps = {
   url: '',
 };
 
+const TimeTableStyles = styled.div`
+  height: ${props => props.height}px;
+
+  th {
+    z-index: 1; // to cover sparkline
+  }
+`;
+
 class TimeTable extends React.PureComponent {
+  memoizedColumns = memoize(columnConfigs => [

Review comment:
       While this memoized function only takes one parameter, and thus is not subject to _that_ particular pitfall of lodash/memoize, it might be worth using `memoize-one` instead, or refactoring to a function component and using `useMemo` for safety.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org