Troubles with pagination

What seems to be the problem: I have some simple pagination buttons with the requisite wire:click="xxxPage", but (at least) one of the buttons doesn’t respond when it should and does when it shouldn’t…but still works right under some circumstances.

Steps to Reproduce:

  • create and use livewire component for list of resources
  • create and use several blade components for the list and the list elements
  • create custom pagination blade file…with simple previous/next buttons…nothing more
  • have simple route, controller, and view for resource page
  • “call” livewire resource list component from view (within/as a layout component slot)
  • open page in browser
  • see initial resource list and pagination links and note that wire:click seems to be present when expected
  • click on links…get inconsistent results

Are you using the latest version of Livewire: I think so…1.0.3

Do you have any screenshots or code examples: not really ready for that

I’m hoping that someone might know if I’m doing something wrong with my mixing of livewire and laravel 7 blade components. I didn’t think this would be a problem, but now I’m not sure.

I have Laravel 7 blade components for my layout, my list, and my list rows. I have a normal blade view for custom livewire pagination, but I get the same – or worse – results when I use out-of-the-box livewire pagination.

I’m sure I’m doing something wrong or forgetting something, so hopefully someone will have an idea from what I’ve shared here.

Please feel free to ask questions. I’ll continue to simplify and see what happens.

Thx.

I have exactly the same problem. My pagination is rendered correctly, but when I click a page nothing happens. Been working on this project for some time now, so I don’t really know where this stopped working. I’m not sure on how to debug this either.

EDIT
I removed all blade components from the page, and it is working again. There is definitely something going wrong here.

EDIT 2
@travis.elkins Did you have a root node? :crazy_face:

@edwinvdpol I came here to tell you that I made a silly mistake but that I couldn’t remember what I had done to resolve it…

…then I saw your “EDIT 2”. That was the problem. I felt like an idiot, but never came back here to update this post…probably due to a combination of it-works-so-move-on and how-embarrassing. :stuck_out_tongue_winking_eye:

1 Like