Hey,
I want to use the CSS Grid (display: grid) for the infinity scrolling mechanism.
But currently I don't see that I am able to change the styles of the inner div element. The FixedSizeGrid Component just have properties to apply some styles to the outer div. Is there a workaround for it or maybe a finished example how to do it?
You would need to use the innerElementType prop to customize the styles of the inner div...
const innerElementType = ({ style, ...rest }) => (
<div style={{ ...style, display: "grid" }} {...props} />
);
<FixedSizeList innerElementType={innerElementType} {...otherProps} />;
...although I would not expect display: grid to work or have any meaningful change since items are all explicitly absolutely positioned.
Most helpful comment
You would need to use the
innerElementTypeprop to customize the styles of the inner div......although I would not expect
display: gridto work or have any meaningful change since items are all explicitly absolutely positioned.