react-responsive-masonry icon indicating copy to clipboard operation
react-responsive-masonry copied to clipboard

Warning: React does not recognize the `columnsCount` prop on a DOM element.

Open gkpo opened this issue 4 years ago • 5 comments

I'm using react-responsive-masonry with Next.js

"next": "^9.5.5",
"react": "^16.14.0",
"react-dom": "^16.14.0",

I get the following warning, and the columnsCount property doesn't seem to work.

Warning: React does not recognize the columnsCount prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase columnscount instead. If you accidentally passed it from a parent component, remove it from the DOM element.

gkpo avatar Nov 12 '20 15:11 gkpo

I'm having the same issue and the issue is with the package. Not Reacts :(

hutber avatar Nov 03 '21 21:11 hutber

Also it turns out columnsCount is not passed correctly, so we only ever have a 3 column

hutber avatar Mar 06 '23 22:03 hutber

This was never addressed I suppose.

tekfunk avatar Sep 29 '23 14:09 tekfunk

It was not sadly. I think the project is dead

hutber avatar Sep 29 '23 15:09 hutber

I also had a similar error. After a little research its turned out what I used tags between ResponsiveMasonry & Masonry tags. Like...

<ResponsiveMasonry columnsCountBreakPoints={{350: 1, 750: 2, 900: 3}}>

<div>some text </div> // <-- that raised a warning !

<Masonry gutter={'25px'}> 
...smth
</Masonry>
</ResponsiveMasonry>

After I took it outside the warning disappeared.

May be its will be helpful

yiooxir avatar Oct 28 '23 07:10 yiooxir