Returns the current item based on the provided routes and history.
The type of the record for route parameters and data.
The type of the switch item.
An array of switch items representing the different routes.
The history object used for navigation.
Returns the current item based on the provided routes and history.