Skip to content

Instantly share code, notes, and snippets.

@jackmccloy
Created July 20, 2016 16:29
Show Gist options
  • Save jackmccloy/053f26e48b468873bc7c6fa2e2897b8d to your computer and use it in GitHub Desktop.
Save jackmccloy/053f26e48b468873bc7c6fa2e2897b8d to your computer and use it in GitHub Desktop.
import Activity from './pages/Activity';
const indexRoute = {
component: Activity.syncComponent,
};
const App = require('./App');
module.exports = {
path: '/',
component: App,
/* Main Navigation Page */
indexRoute: indexRoute,
getChildRoutes(location, callback) {
require.ensure([], function childRouteFunc(require) {
callback(null, [
// site
require('./pages/About'),
require('./pages/Activity'),
require('./pages/Members'),
// user
require('./pages/Login'),
require('./pages/Logout'),
require('./pages/Profile'),
require('./pages/Signup'),
// admin
require('./pages/Dashboard'),
// 404
// require("../pages/NotFound")
]);
});
},
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment