PaginationEx (PaginationEx v0.1.0)

PaginationEx provides pagination functionality for Elixir applications.

Summary

Functions

Builds the URL for a specific page. Useful for custom pagination templates.

Paginates results in groups.

Creates a new pagination struct from a query and params.

Generates the "Next" link or disabled button based on the current page and total pages. Useful for custom pagination templates.

Generates numeric links for each page. Useful for custom pagination templates.

Renders pagination links in HTML.

Generates the "Previous" link or disabled button based on the current page. Useful for custom pagination templates.

Translates text using configured Gettext module if available. Useful for custom pagination templates.

Functions

build_url(conn, path, page)

Builds the URL for a specific page. Useful for custom pagination templates.

in_groups(query, params \\ %{})

Paginates results in groups.

new(query, params, opts \\ [])

Creates a new pagination struct from a query and params.

next_path(conn, path, current_page, total_pages)

Generates the "Next" link or disabled button based on the current page and total pages. Useful for custom pagination templates.

page_links(conn, path, pagination)

Generates numeric links for each page. Useful for custom pagination templates.

paginate(conn, path, opts \\ [])

Renders pagination links in HTML.

previous_path(conn, path, current_page)

Generates the "Previous" link or disabled button based on the current page. Useful for custom pagination templates.

translate(text)

Translates text using configured Gettext module if available. Useful for custom pagination templates.