I'm using react-router-dom to manage my routes:
<Routes>
<Route path="/" element={<MainLayout />}>
<Route index element={<Home />} />
<Route path="@:profileId" element={<Profile />} />
</Route>
<Routes>
I want to use @ prefix at profile route but error is no routes matched location "/@username"
How to fix it?
CodePudding user response: