Ad
  • Custom User Avatar

    Just experienced this issue, still seems like a problem.

  • Custom User Avatar

    I still find this example and test very confusing:

    Another example:
    
    Total pages: 36
    Current page: 1
    Items before and after: 5
    Expected [1 (always) 2,3,4,5,6 (5 before) ,7, (center) 8,9,10,11,12, (5 after) 36] (always)
    

    I don't understand where center comes from here.

    I think a clearer implementation would just be to show 5 pages before and after the current page. But if you hit either the first page or the last page, then you show the extra pages after the current page.

    So here, given that 1 is the current page, I think showing 10 pages beyond 1. The center thing just doesn't make sense to me.