Skip to main content

pagination_link_header

Function pagination_link_header 

Source
pub fn pagination_link_header(
    path: &str,
    query: &QueryParams,
    limit: usize,
    offset: usize,
    total: usize,
) -> String
Expand description

Build the RFC 8288 Link header value for a paginated collection.

The value is empty when the page size is zero, because there is then nothing to page through.