Fix/request manager infinite swr requests (#306)
* Fix RequestManager initial infinite swr requests Functions always returned "null" as the url, which causes SWR to not send the request - useGetSourceLatestMangas - useSourceSearch - useSourceQuickSearch * Use "skipRequest" for infinite SWR requests Is easier to use then overwriting "getEndpoint" only for specific cases * Request correct first page for infinite SWR requests The following endpoints start at page 1 - popular source mangas - latest source mangas - source search - source quick search * Remove wrong parameter from source manga browse requests No idea why I've added this in the first place * Correctly request "latest" and "popular" source mangas The "page" wasn't a param of the query but part of the endpoint
This commit is contained in:
@@ -330,6 +330,11 @@ export interface PaginatedList<T> {
|
||||
hasNextPage: boolean;
|
||||
}
|
||||
|
||||
export type PaginatedMangaList = {
|
||||
mangaList: IManga[];
|
||||
hasNextPage: boolean;
|
||||
};
|
||||
|
||||
export type NullAndUndefined<T> = T | null | undefined;
|
||||
|
||||
export type ChapterSortMode = 'fetchedAt' | 'source';
|
||||
|
||||
Reference in New Issue
Block a user