Pagination

Table (gem footer pager) Cards (kaminari default pager)
How this page is built the gem renders it — this is all you write

Pagination works in a custom layout too. You still paginate in the controller (kaminari); the cards layout feeds collection.page_scope to kaminari's own paginate helper, so the pager below is kaminari's default markup — styling it is your job, as always with kaminari.

app/controllers/books_controller.rb
@query = CrudComponents::Query.new(Book, params, fieldset: :index, ability: current_ability)
@books = @query.apply(Book.all).page(params[:page]).per(8)   # kaminari
app/views/crud_components/layouts/_cards.html.erb
<%= paginate collection.page_scope %>   <%# kaminari's own pager, inside your card layout %>
app/views/pagination/index.html.erb
<%= crud_collection @books, query: @query, layout: :cards %>

Read more: Pagination  ·  Add a layout

The Ancient Ocean 17
Author names
Martha Wells, Ted Chiang, and Stanisław Lem
Genre
Fiction
Price
34.01 €
Publisher
Baen
Active
The Endless Forest 18
Author names
Octavia Butler, Ann Leckie, and Liu Cixin
Genre
Scifi
Price
11.84 €
Publisher
Del Rey
Active
The Ancient Ocean 19
Author names
Frank Herbert
Genre
Fiction
Price
43.54 €
Publisher
Baen
Active
The Endless Mirror 20
Author names
Stanisław Lem and Ted Chiang
Genre
Scifi
Price
21.82 €
Publisher
DAW
Active
The Hidden Dune 21
Author names
Octavia Butler
Genre
Nonfiction
Price
16.41 €
Publisher
Orbit
Active
The Hidden Door 22
Author names
Frank Herbert
Genre
Fiction
Price
30.21 €
Publisher
Baen
Active
The Burning Door 23
Author names
Ann Leckie and Martha Wells
Genre
Fiction
Price
15.15 €
Publisher
Gollancz
Active
The Dispossessed Winter 24
Author names
Ted Chiang
Genre
Nonfiction
Price
19.40 €
Publisher
Del Rey
Active