Skip to content

Instantly share code, notes, and snippets.

@iamnnort
Last active February 11, 2017 22:38
Show Gist options
  • Save iamnnort/6a79c781d165bdd3de28aa257d663756 to your computer and use it in GitHub Desktop.
Save iamnnort/6a79c781d165bdd3de28aa257d663756 to your computer and use it in GitHub Desktop.
import React from 'react'
import { Route, IndexRedirect } from 'react-router'
import App from './containers/App'
import List from './components/List'
import Video from './components/Video'
import NotFound from './components/NotFound'
export const routes = (
<div>
<Route path='/' component={App}>
<IndexRedirect to='list' /> {/* INDEX REDIRECT */}
<Route path='/list' component={List} />
<Redirect from='/photo' to='/video' />
<Route path='/video' component={Video} />
</Route>
<Route path='*' component={NotFound} />
</div>
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment