Livewire

Livewire v4 Pagination: Simple and Cursor-Based

February 01, 2026 1 min read 16 views

Livewire v4 provides seamless pagination.

Simple Pagination

use Livewire\WithPagination;

class PostList extends Component
{
    use WithPagination;
    
    public function render()
    {
        return view('posts', ['posts' => Post::paginate(10)]);
    }
}

Template

@foreach($posts as $post)
{{ $post->title }}
@endforeach {{ $posts->links() }}
Share this post:

Related Posts

Comments (0)

Please log in to leave a comment. Log in

No comments yet. Be the first to comment!