2016-07-15 15:05:04 -03:00
|
|
|
import React from 'react';
|
|
|
|
import { Route, IndexRoute } from 'react-router';
|
|
|
|
import App from '../containers/App';
|
2016-11-02 12:25:43 -02:00
|
|
|
import DashboardPage from '../containers/DashboardPage';
|
2016-07-15 15:05:04 -03:00
|
|
|
import CollectionPage from '../containers/CollectionPage';
|
|
|
|
import EntryPage from '../containers/EntryPage';
|
|
|
|
import SearchPage from '../containers/SearchPage';
|
|
|
|
import NotFoundPage from '../containers/NotFoundPage';
|
|
|
|
|
|
|
|
export default (
|
|
|
|
<Route path="/" component={App}>
|
2016-11-02 12:25:43 -02:00
|
|
|
<IndexRoute component={DashboardPage} />
|
|
|
|
<Route
|
|
|
|
path="/collections/:name"
|
|
|
|
component={CollectionPage}
|
|
|
|
/>
|
|
|
|
<Route
|
|
|
|
path="/collections/:name/entries/new"
|
|
|
|
component={EntryPage}
|
|
|
|
newRecord
|
|
|
|
/>
|
|
|
|
<Route
|
|
|
|
path="/collections/:name/entries/:slug"
|
|
|
|
component={EntryPage}
|
|
|
|
/>
|
|
|
|
<Route
|
|
|
|
path="/search/:searchTerm"
|
|
|
|
component={SearchPage}
|
|
|
|
/>
|
|
|
|
<Route
|
|
|
|
path="*"
|
|
|
|
component={NotFoundPage}
|
|
|
|
/>
|
2016-07-15 15:05:04 -03:00
|
|
|
</Route>
|
|
|
|
);
|