Created
November 15, 2017 23:22
-
-
Save eh3rrera/6e4afa00e1802ce8e3f92adb8643cf2b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// … | |
import { | |
Route, | |
Link, | |
Switch, | |
Redirect | |
} from 'react-router-dom' | |
// … | |
class App extends Component { | |
render() { | |
return ( | |
… | |
<div className="App-intro"> | |
<Switch> | |
<Route exact path="/" component={Home} /> | |
<Route path="/messages" component={Messages} /> | |
<Route path="/about" component={About} /> | |
<Redirect to="/" /> | |
</Switch> | |
</div> | |
</div> | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment