1234567891011121314151617181920 |
- import About from "./modules/About";
- import App from "./modules/App";
- import Home from "./modules/Home";
- import React from "react";
- import Repos from "./modules/Repos";
- import Repo from "./modules/Repo";
- import { render } from "react-dom";
- import { IndexRoute, Router, Route, browserHistory as history} from "react-router";
- render((
- <Router history={history}>
- <Route path="/" component={App}>
- <IndexRoute component={Home} />
- <Route path="/repos" component={Repos}>
- <Route path="/repos/:userName/:repoName" component={Repo} />
- </Route>
- <Route path="/about" component={About} />
- </Route>
- </Router>
- ), document.getElementById("app"));
|