Questions tagged [pagination]
Pagination is the process of dividing information into discrete pages.
121
questions
0
votes
1
answer
65
views
golang HTTP client that follows pagination header
I'm new to Go from another language and I'm most interested to know if this implementation has anything that's not idiomatic Go, but any feedback is welcome and you're not going to hurt my feelings by ...
0
votes
1
answer
101
views
PHP pagination function
After reviewing my previous question I came up with this pagination function. On my first approach I wrote a class thinking about IDE's code assist and the review wasn't positive. In this function I ...
2
votes
1
answer
88
views
PHP Pagination class (Clase para paginar resultados)
This is my first question in Code Review. I apologize in advance for using Spanish (my native language). I thought there was a spanish version of Code Review.
This class is meant for pagination. It ...
3
votes
1
answer
592
views
Client side Pagination implementation in vanilla js
I have made this Pagination Class in JS which takes the following configurations :-
Total records
Records per page
Visible pages
The idea is simple that any instance created using this Pagination ...
1
vote
0
answers
364
views
Calling PagerDuty REST API to recursively fetch oncall info for a team
I am a beginnner and have put up a code that talks to pagerduty API and then it fethces oncall info for a team (get team id, get escalation policy id, then finally get on call info). response is ...
3
votes
1
answer
145
views
Angular - Contact manager component with API
I am starting with the Angular and I need some support. I have watched some of the tutorials and lot of them are using things differently. I upgraded some tutorial with my own idea, but I am not sure ...
0
votes
1
answer
3k
views
What is the best way to retrieve all pages of a REST API route with Python aiohttp when the number of pages is unknown?
I've encountered a paginated API route where there is no way to know the number of available pages. The only way to retrieve every pages is to check on each page if a next page exists. To do so, the ...
6
votes
3
answers
263
views
Python grouped iterator
I wanted to write an iterator that would split items up into groups, so I can bulk insert into MySQL without crashing or overwhelming the server.
This is the implementation I came up with.
I am hoping ...
2
votes
1
answer
349
views
table pagination
What I'm trying to do is quite simple: my table has pagination. So if I have 12 items to show and my max items per page is 10, I will have 2 pages, one with 10 records and another with just 2. I ...
3
votes
1
answer
115
views
Pagination helper class
The most nauseous problem with pagination is the fact that you have to write two almost identical queries. For the various reasons I am not inclined to use the SQL-only way (such as ...
2
votes
1
answer
132
views
basic paging function, is there logical problems with the JavaScript part?
Basic paging function, is there logical problems with the JavaScript part?
very basic paging function.
I want to know if there are some problems in the logic of the code.
I feel the JS code is a bit ...
2
votes
1
answer
80
views
Optimize KnockoutJs Pagination Computed Function
I have written a function that builds an array of paging options for rendering on the view.
I have modelled it after DataTables for jQuery, a live example with lots of data is available here: http://...
2
votes
0
answers
38
views
Cursor-based search result pagination
Can you guys review my GraphQL search pagination function? I'm afraid there could be some performance issues, or something. Especially at the aggregation section and this ...
2
votes
1
answer
4k
views
Java pagination algorithm
I made a pagination algorithm but in my opinion it is too complicated and it is quite difficult to be understood. This algorithm should show 5 pages where in the middle is the current page. It should ...
1
vote
0
answers
96
views
Make Pagination using Ajax with Jquery, PHP [closed]
This is the first time that I have add (I mean, I try) Ajax with Jquery to PHP and Mysql (pagination). This is a link to the test page: testpage1
I think everything works, but is it done correctly?
...
3
votes
0
answers
963
views
Pagination For Qt's Listview
I'm creating a generic pagination helper class.
Personally I use this class for navigating through Records which are loaded into
any sequential containers e.g ...
1
vote
1
answer
115
views
How can I optimize my pagination code?
I'm building a page in LWC this page consist of a table, you can search, sort and paginate with this table.
When the first element is selected:
when the last element is selected:
When the middle ...
3
votes
1
answer
155
views
Paginating a Backbone collection
This is part of a class for paginating a Backbone collection.
The paginateTo method is for paginating to a model id. It returns ...
2
votes
0
answers
1k
views
Redux pagination transducer
Motivation
In my web app (React, Redux, TypeScript) we have a common need to write paginated API calls, with various UI interactions (infinite scroll, prefetch pages in the background, or manual page ...
2
votes
1
answer
213
views
Listing employees, categorized by license expiration date
I am working on a personal project and I have hit a wall. I know I am writing bad code and I really want to refactor the code below. The application has three tables on the same page. Each table ...
5
votes
1
answer
874
views
Laravel Pagination with haversine formula in it
I'm using the haversine formula to count distance from selected post-code to desired destination.
I have the following scope in ...
4
votes
1
answer
80
views
Paginating API with "next" Pythonically
I'm wondering if there's a more Pythonic way to keep paginating an API endpoint until there's no next key in the response. The thing that bothers me the most is the ...
3
votes
1
answer
105
views
PHP complete pagination code
I'm working on a site where you can read about different songs, listen to them, rate them etc, same with their singer.
I've been thinking about how I could create a simple, yet perfectly working ...
1
vote
0
answers
132
views
Angular pagination component
I have written an Angular component for pagination. It works like this:
page count < 12
all pages are shown
Example:
< 1 2 *3* 4 5 6 >
page count >= ...
5
votes
1
answer
607
views
how to make pagination more efficient with large arrays and db support
i have a pagination library in php. i want to know:
how can i make it more efficient when passing large arrays into the constructor
how can i add db support
paginator.php
...
1
vote
0
answers
56
views
Paginating a paginated API response
I have an application which requests data from a REST endpoint 50 items at a time and displays results in the UI. I would like to paginate each API response into smaller arrays for display and then ...
3
votes
1
answer
1k
views
Pagination calculation
I have written a function to get the actual page range to display that page range in pagination.
My function is working properly. But I think that I have written bad code. Can someone review my code ...
1
vote
1
answer
101
views
Displaying a paginated list of forum topics using PHP PDO [closed]
Can someone tell me if this code is safe? Can be sql-injected or something else hacked? Code get some rows from db and show in pages with pagination... if i can improve let me know and show me how, ...
3
votes
1
answer
2k
views
Create Products TableView with PAGINATION and LIKE product feature in RxSwift MVVM
I have tried to develop a simple product listing app in RxSwift with MVVM design pattern. I have managed to achieve it but I need someone to review my code, such as:
Have I followed the proper ...
3
votes
0
answers
91
views
Paginator module in Elixir
I wrote this Paginator module that's part of a small application that displays Elixir Github repos in a table.
I'm new to Elixir and looking for code improvements with as much as possible. Best ...
7
votes
2
answers
2k
views
Version of C# StringBuilder to allow for strings larger than 2 billion characters
In C#, 64bit Windows, .NET 4.5 (or later), and enabling gcAllowVeryLargeObjects in the App.config file allows for objects larger than two gigabyte. That's cool, but ...
2
votes
1
answer
86
views
Function to filter comments and ratings, with pagination support
I have a web component that is rendering a list of items and I have this method for filtering these items based in a filterBy object that is being updated by other ...
4
votes
1
answer
2k
views
Change the limit from CakePHP 3 Paginator by click in link inside an <option>
I'm using the CakePHP 3.0 to paginate some content, but I can't find a way to change the limit (user on browser choose the limit of content displayed on screen) using ...
2
votes
1
answer
595
views
Offset vs Cursor Pagination
I am trying to compare any performance gain(s) from moving a current offset-based pagination endpoint to a cursor based one.
I have the following ruby code:
...
6
votes
3
answers
2k
views
Generating pagination links
I recently had an interview for a programming job and after the interview I was then asked to create a function with the following brief:
The Task:
Relating to pagination links: given a page number, ...
2
votes
1
answer
144
views
List component using RXJS Angular
I have a small angular project, where I have an Article component to list articles with pagination system.
The default page
The placeholder loader page
The main objectives are:
Display the ...
2
votes
1
answer
538
views
Paginated AngularJS posts application
I have made a small application that displays a posts JSON in the form of cards, with the help of AngularJS and Twitter Bootstrap 4.
The application has an interface for pagination and there are ...
2
votes
2
answers
4k
views
MVC simple Employee table with paging using SP
I am a beginner web developer and I have to do an exercise to show an Employee table using a WCF service, 10 entries at a time, with the paging of the table controlled by a stored procedure. What I ...
0
votes
2
answers
218
views
Web scraping and speeding up performance
I was wondering if the following code could be altered to speed up the scraping process. I know xrp has many transactions, but it takes an hour to go through half a day of transactions (at the busiest ...
1
vote
1
answer
1k
views
React container component to fetch paginated data for a stateless table component
TableContainer.js does the common task of fetching data and passing it to a lower component, Table.js, which is a stateless ...
5
votes
1
answer
2k
views
React app with table, search & pagination
I'm new to React. I major in Angular. And for me it's realy not so obvious here... Do I use this props & state variables in a good way or do I need to refactor/change something?
Main goal is such:...
1
vote
1
answer
486
views
Displaying pagination links, maybe with links to first and last page
I've been researching if this is possible, but I've drawn a blank, I'm wondering if it's possible to optimize these for and if statements together?
...
4
votes
1
answer
175
views
Determining if there is data left after fetching a page of data
I just faced a problem where I needed to know if extra data was present in a given collection after a Take operation took place. Specifically, this is related to ...
3
votes
1
answer
342
views
React pagination without JSX
I've published my first react project for pagination purposes. It's likely I'm making mistakes or there are any improvements to my code. I'd appreciate if anyone has any offers.
...
7
votes
1
answer
680
views
Setting up pagination links inside a WebAPI Controller
I'm implementing paging for the first time and have the following code which achieves what I want.
There are just a couple of things that feel a bit weird to me and would like if somebody could give ...
10
votes
1
answer
561
views
Simple pager in C
I have written a simple pager in C. It works fine for most things, but I'd like to know how it can be improved. Specific things I'm looking for are if there are size and/or speed improvements to be ...
8
votes
1
answer
429
views
Non-curses pager in C
I have written a pager in C that is supposed to be used in systems where curses is not installed (or broken). It can also be used as a system-wide pager, it works ...
2
votes
3
answers
2k
views
PHP page pagination
I think my code is sloppy can anyone give me advice to do it better?
This is a page pagination that get rows from mysql db and calculate the number of pages.
...
10
votes
2
answers
17k
views
Pagination algorithm in JS
I needed a relatively simple pagination, as currently implemented on GoogleSearch (sans prev & next buttons). Most code I've seen was overly complicated so I came up with something that's simpler. ...
2
votes
1
answer
768
views
Bootstrap pagination
Here is my bootstrap pagination code. Maybe it can be simplified.
...