andreypopp/react-router-component — pull request #52 by parshap (2014-04-25 22:44:37+00:00)
Title: Contextual routers and "index pages"

I have router that handles a `/profile` route using a contextual router. For example:

```

```

A request to `/profile` will cause an invariant violation because there is no `unmatchedPath` left from the parent router.

I want to *ProfileRouter* contextual router to be able to handle requests for `/profile` as if there was a sort of "index page". It should match the *ProfileRouter*'s route for `/`.

This patch defaults the `unmatchedPath` portion of the *match* object to `/` if there is no remaining match from the parent.