-
-
Notifications
You must be signed in to change notification settings - Fork 12
Root: ui|v2.5|src|components|Performers: Performers.tsx
Serechops edited this page Apr 10, 2024
·
1 revision
This file contains two React functional components: Performers
and PerformerRoutes
, responsible for managing routes related to performers in the application.
- This component is a functional component responsible for rendering the list of performers.
- It utilizes the
useScrollToTopOnMount
hook to ensure that the page scrolls to the top when mounted. - It renders the
PerformerList
component, passingPersistanceLevel.ALL
as thepersistState
prop.
- This component is a functional component responsible for defining routes related to performers.
- It uses the
useTitleProps
hook to get the title properties for the page and sets them using theHelmet
component fromreact-helmet
. - It utilizes the
Switch
component fromreact-router-dom
to render different routes based on the URL path.- The route
/performers
renders thePerformers
component. - The route
/performers/new
renders thePerformerCreate
component, which is responsible for creating a new performer. - The route
/performers/:id/:tab?
renders thePerformer
component, which is responsible for displaying details of a specific performer. The:id
parameter represents the performer's ID, and:tab?
is an optional parameter for specifying a tab within the performer details page.
- The route
<PerformerRoutes />
This component should be included in the main routing setup of the application to handle performer-related routes and render the appropriate components based on the URL path.