dantrain/react-stonecutter

React does not recognize the `itemHeight` prop on a DOM element

zanedev opened this issue · 2 comments

Hi when adding itemHeight to an li to a css grid like the example I get the message React does not recognize the itemHeight prop on a DOM element. When I remove the prop I get a warning Uncaught Error: Each child must have an "itemHeight" prop or an "itemRect.height" prop. How can I work around this?

Can you post a code snippet?

This is a standard warning with react-16.9.0 it doesn't allow custom props on an html element.

<li key={key} itemHeight={image.images.low_resolution.height}>
  <img src={image.images.low_resolution.url} />
</li>