(This PR introduces a pagination feature to the HNG-boiler-plate-Remix application due to the issue [FEAT] External Dynamic Pages > Career Page > Implement Pagination https://github.com/hngprojects/hng_boilerplate_remix/issues/93. CLOSED BY MISTAKE MERGING AN EMPTY PR)
Add Pagination Component and Job Listing Feature for Career Page
PR Description:
This PR introduces a pagination component and integrates it with the job listing feature on the career page. The new pagination system allows users to navigate through multiple pages of job listings seamlessly. Below are the key features and implementation details:
Features:
Pagination Component:
Pagination: Container for the pagination navigation.
PaginationContent: Holds the pagination items.
PaginationItem: Represents an individual page item.
PaginationLink: Link for each page, styled according to its state (active/inactive).
PaginationPrevious and PaginationNext: Navigation links to move to the previous or next page.
PaginationEllipsis: Ellipsis for indicating skipped pages.
Job Listing Integration:
CareerPage: A page that displays job listings with pagination controls.
Dynamically generates page numbers based on the current page and total pages.
Adjusts the number of visible page links based on the window width.
How to Use:
To use the pagination component and fetch a job list, follow these steps:
Loader Function:
The loader function fetches job listings based on the current page from the URL query parameters.
If the page number is invalid, it returns a 404 response.
implement pagination for career page:
(This PR introduces a pagination feature to the HNG-boiler-plate-Remix application due to the issue [FEAT] External Dynamic Pages > Career Page > Implement Pagination https://github.com/hngprojects/hng_boilerplate_remix/issues/93. CLOSED BY MISTAKE MERGING AN EMPTY PR)
Add Pagination Component and Job Listing Feature for Career Page
PR Description:
This PR introduces a pagination component and integrates it with the job listing feature on the career page. The new pagination system allows users to navigate through multiple pages of job listings seamlessly. Below are the key features and implementation details:
Features:
Pagination Component:
Pagination
: Container for the pagination navigation.PaginationContent
: Holds the pagination items.PaginationItem
: Represents an individual page item.PaginationLink
: Link for each page, styled according to its state (active/inactive).PaginationPrevious
andPaginationNext
: Navigation links to move to the previous or next page.PaginationEllipsis
: Ellipsis for indicating skipped pages.Job Listing Integration:
CareerPage
: A page that displays job listings with pagination controls.How to Use:
To use the pagination component and fetch a job list, follow these steps:
Loader Function:
loader
function fetches job listings based on the current page from the URL query parameters.CareerPage Component:
CareerPage
component uses theuseLoaderData
hook to fetch job listings data.Additional Notes:
dummyJobListings
function is used to simulate job listings data. Replace this with your actual data fetching logic.