message: undo heavy cell lazyloading due to render flashing
diff: -import React, { Suspense, useEffect, useState } from "react";
  +import React, { Suspense } from "react";
  import { FormatterProps } from "react-data-grid";
  import { makeStyles, createStyles } from "@material-ui/core";
  @@ -34,6 +34,32 @@ const getCellValue = (row, key) => {
  * @param Component The formatter component to display
  * @param readOnly Prevent the formatter from updating the cell value
  */
  +const withCustomCell = (
  + Component: React.ComponentType<CustomCellProps>,
  + readOnly: boolean = false
  +) => (props: FormatterProps<any>) => {
  + useStyles();
  + const { updateCell } = useFiretableContext();
  +
  + const handleSubmit = (value: any) => {
  + if (updateCell && !readOnly)
  + updateCell(props.row.ref, props.column.key as string, value);
  + };
  + return (
  + <ErrorBoundary fullScreen={false} basic wrap="nowrap">
  + <Suspense fallback={<></>}>
  + <Component
  + {...props}
  + docRef={props.row.ref}
  + value={getCellValue(props.row, props.column.key as string)}
  + onSubmit={handleSubmit}
  + />
  + </Suspense>
  + </ErrorBoundary>
  + );
  +};
  +
  +/*
  const withCustomCell = (
  Component: React.ComponentType<CustomCellProps>,
  readOnly: boolean = false
  @@ -64,5 +90,5 @@ const withCustomCell = (
  };
  return component;
  };
  -
  +*/
  export default withCustomCell;
  