yesod-paginator-0.10.1: A pagination approach for yesod

Safe HaskellNone
LanguageHaskell98

Yesod.Paginator.Widget

Synopsis

Documentation

getCurrentPage :: Yesod m => HandlerT m IO Int Source #

looks up the "p" GET param and converts it to an Int. returns a default of 1 when conversion fails.

paginationWidget :: Yesod m => PageWidgetConfig -> PageWidget m Source #

A widget showing pagination links. Follows bootstrap principles. Utilizes a "p" GET param but leaves all other GET params intact.

defaultPageWidgetConfig :: PageWidgetConfig Source #

Default widget config provided for easy overriding of only some fields.

type PageWidget m = Int -> Int -> Int -> WidgetT m IO () Source #

currentPage, itemsPerPage, totalItems -> widget

data PageWidgetConfig Source #

Constructors

PageWidgetConfig 

Fields