There are a few things to improve concerning types related to page and pager.
pageTag
Actual type
pageTag: string
Proposed type
type PageNumber = number;
type SubPageNumber = number;
type IterationNumber = number;
type PageTag = `${PageNumber}` | `${PageNumber}.${SubPageNumber}#${IterationNumber}`;
pageTag: PageTag
type Pager = {
lastReachedPage?: PageTag;
maxPage: number; //Or PageTag if it's possible but i dont think
nbSubPages?: number;
page: number;
subPage?: number;
// Iteration index (starting at 0)
iteration?: number;
nbIterations?: number;
shallowIteration?: number;
linksIterations?: number[];
};
pager: Pager
Improve type related to page and pager
There are a few things to improve concerning types related to page and pager.
pageTag
Actual type
Proposed type
pager
Actual type
Proposed type
goToPage
Actual type
Proposed type
Priority