import { RouterProvider, createBrowserRouter, createRoutesFromElements, Route } from 'react-router-dom';
const router = createBrowserRouter(
createRoutesFromElements(
<Route
path="/"
element={<Main filterCardsText={filterCardsText} isTitlePending={isTitlePending} />}
>
<Route
path="more"
element={<More />}
/>
<Route
path="all-cards"
element={<Cards />}
/>
</Route>
)
)
return (
<div className="wrapper">
<Header setFilterCardsText={setFilterCardsText} startTitleTransition={startTitleTransition} />
<RouterProvider router={router} />
<Footer />
</div>
)
import { RouterProvider, createBrowserRouter, createRoutesFromElements, Route } from 'react-router-dom';
const router = createBrowserRouter(
createRoutesFromElements(
<Route
path="/"
element={<Main filterCardsText={filterCardsText} isTitlePending={isTitlePending} />}
>
<Route
path="more"
element={<More />}
/>
<Route
path="all-cards"
element={<Cards />}
/>
</Route>
)
)
return (
<div className="wrapper">
<Header setFilterCardsText={setFilterCardsText} startTitleTransition={startTitleTransition} />
<RouterProvider router={router} />
<Footer />
</div>
)