Question: I'm trying to routing the path in my web, but it is not working. I'm looking forward for advice to fix this problem. Thanks for advance. 

Code in index.js

```
<BrowserRouter>
    <Switch>
        <Route exact path="/login" component={Login} />
        <Route path="/dashboard" name="Home" component={Home} />
        <Route component={Login} />
    </Switch>
</BrowserRouter>

```

Code in Home.js

```
<div>
   <Header/>
      <div className="main">
      <div className="container-fluid">
        <Switch>
          <Route path="/dashboard" name="Dashboard" component={Dashboard} />
          <Route path="/problems" component={ProblemList}/>
          <Redirect from="/" to="/dashboard" />             
        </Switch>
      </div>
      </div>
   <Footer/>
</div>

```

The path that is not working is "/problems". It is a component which is located in the folder with Dashboard.(The dashboard is working as I press the navbar but ProblemList isn't.)

Answer: 
If you are using `href="/"` - try to add after it *to* with the same path, like this to = "/".
If your link is <http://localhost:3000/problems>, then in your index.js you should add '/problems'. Then only your app will be able to detect the component to be shown while its in this path.

```
<BrowserRouter>
    <Switch>
        <Route exact path="/login" component={Login} />
        <Route path="/dashboard" name="Home" component={Home} />
        <Route path="/problems" component={ProblemList}/>
        <Route component={Login} />
    </Switch>
</BrowserRouter>

```