Skip to content

Add pagination combinators #7

Description

@flupe

For static-site generation purposes, it's required to provide combinators such as the following:

chunks :: Task m Int -> Task m [a] -> Task m [[a]]

(We have the above already, although change info may be incorrect).

But something along those lines would be nice:

paginate :: Task m [a] -> Task m [(a, These a a)]

paginate
  :: Task m [a] 
  -> (Task m a -> Task m (i, b))
  -> (Task m b -> Task m (These i i) -> c)
  -> Task m [c]

Again, more thinking should go into this.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

  • Status
    Todo

Relationships

None yet

Development

No branches or pull requests

Issue actions