cedricdelpoux / react-responsive-masonry

React responsive masonry component built with css flexbox
https://cedricdelpoux.github.io/react-responsive-masonry/
MIT License
362 stars 37 forks source link

Ignore null/falsy children in Masonry #43

Closed RavdeepSingh99 closed 3 years ago

RavdeepSingh99 commented 3 years ago

This commit is the fix for https://github.com/cedricdelpoux/react-responsive-masonry/issues/42 issue.

In this, we simply ignore falsy children to get added in the columns array so that this doesn't break the UI.

cedricdelpoux commented 3 years ago

@RavdeepSingh99 Thank you for this PR and sorry for the delay. I just want you clarify why the first condition. Thank you