Created
April 7, 2018 07:27
-
-
Save EdsonAlcala/ff390a845587d5e9709d6a614dcef24c to your computer and use it in GitHub Desktop.
This file contains hidden or 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 React from 'react'; | |
import { Switch, Route, BrowserRouter as Router } from 'react-router-dom'; | |
import Home from './containers/Home'; | |
import NewProposal from './containers/NewProposal'; | |
import ProposalDetail from './containers/ProposalDetail'; | |
import Proposals from './containers/Proposals'; | |
import Results from './containers/Results'; | |
const Routes = () => ( | |
<Router> | |
<Switch> | |
<Route exact path="/" component={Home} /> | |
<Route path="/newproposal" component={NewProposal} /> | |
<Route path="/proposaldetail/:proposalId" component={ProposalDetail} /> | |
<Route path="/proposals" component={Proposals} /> | |
<Route path="/results" component={Results} /> | |
<Route component={Home} /> | |
</Switch> | |
</Router> | |
) | |
export default Routes; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment