askides / react-plock

The 1kB Masonry Grid for React.

Home Page:https://react-plock-with-nextjs.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Plock grid re-hydration on URL search query change in Next.js, which might cause a delay in onClick events of grid items.

rahulcn opened this issue · comments

Possible steps to reproduce,

  1. Add an onClick event on the items to update URL search params.
  2. The click event is not working sometimes, It's not consistent though.
  3. Try making the cursor out of focus in the inspector and click directly on the item.
  4. It is recreating the grid on every item click.

Also, there is a delay in Masonry formation, after the DOM hydrates it takes a second to form masonry grid. Is there a config or possible fix?

Hi!

Could you please provide a Sandbox showing the issue you are talking about?

It will be helpful for debug.

Many thanks.

Close due to inactivity.

Please check out the new v3.0.0 version just published. In addition to a number of performance and bundle size improvements, the problem you reported probably has been fixed.