react-router two forward slash not rendering the component

  reac, react-router, reactjs

I have a component that needs to render on this route below but it’s not rendering. How can I make this work? It’s only working if I replace it with dashed /user-history without extra slash

export const HISTORY = '/user/history';

<Route exact path={ROUTES.HISTORY} component={History} />

Source: React Router Questions

LEAVE A COMMENT