是否可以在react-router
v4中创建普通路由?
Ex(v3版本):
const routes = {
path: '/',
indexRoute: {onEnter: (nextState, replace) => replace('/calendar')},
childRoutes: [
{path: '/calendar', component: CalendarContainer},
{path: '/booking/:id', component: BookingContainer}
]
};