import React from 'react'; import CollectionsOverview from '../../components/collections-overview/collections-overview.component'; import {Routes, Route} from 'react-router-dom'; import CategoryPage from '../category/category.component'; const ShopPage = ({match}) =>{ return (<div className="shop-page"> <Routes> <Route exact path={ `${match.path}` } element={<CollectionsOverview />}/> <Route exact path={ `${match.path}/:categoryId`} element={<CategoryPage/>}/> </Routes> </div> )}; export default ShopPage;La match de valor de propiedad no está definida, lo que significa que dondequiera que esté utilizando el componente ShopPage , no ha definido el atributo o el valor del atributo no está definido.
Por lo tanto, cámbielo a algo como:
<ShopPage match={somethinghere} />