React Typescript Pagination Array Page Numbers
I have a paginated table and the footer displays the number of pages like this
◀ 1
2 3 4 5 6 7 8 9 10
▶ but I'm trying to make the page numbers look like this ◀️ 1 2 3 . . . 9 10
▶️
FooterPagination.tsx
<div className="pagination-col2">
<div onClick={() =>{
setPage(page - 1)
}} className="left"><FaAngleLeft className='icon'/></div>
{range?.map((el, index) =>{
return(
<div key={index}>
<div className='range-spread'>{el}</div>
</div>
)
})}
<div onClick={() =>{
setPage(page + 1)
}} className="right"><FaAngleRight className='icon'/></div>
</div>
0 Replies