I am using React 0.14.0, React Router 2.0.0-rc4, browser 11.2.0, babelify 7.2.0.
Here is my router code:
render((
<Router history={browserHistory}>
<Route path="/" component={App}>
<IndexRoute component={Departments} />
<Route path="goals" component={Goals} />
<Route path="departments" component={Departments} >
<Route path="department" component={Department} />
</Route>
</Route>
</Router>
), document.getElementById('react-container'))
root / department works fine, but not root / department /. root / department / department does not work either. I'm not sure why.
It also seems that any parameter matters: myParam is not recognized.
I do not see any difference between my code and the examples given in the documentation.
Another weird thing: I have no warning:
Warning: [react-router] Location "undefined" did not match any routes
I have:
Uncaught SyntaxError: Unexpected token < bundle.js:2
And if I click on the bundle.js link in the chrome dev tools, I come in index.html (but bundle.js is the name of the tab).
Major routes, such as /, departments and goals, work fine.
I'm kinda stuck on this. Any advice would be helpful.
: https://github.com/codeforabq/Open-Budget-ABQ/tree/dev
.