We are using react-router like so:
ReactDOM.render(
<Router>
<Route path="/" component={AnyPic}>
<Route path="p/:photoId" component={PhotoView} />
</Route>
</Router>,
document.getElementsByClassName("container")[0]
);
var AnyPic = React.createClass({
render: function() {
return (
<p>Hello world</p>
)
}
});
var PhotoView = React.createClass({
render: function(){
return (
<p>This is the photo view</p>
)
}
});
After including react-router, what used to be just localhost:8000 started looking like localhost:8000/#/?_k=wulhmi. Not sure where those extra params came from.
Anyway, when trying to access localhost:8000/#/p/XYZ the page keeps going back to /. Any help would be much appreciated.
AnyPicandPhotoViewlook like? Are there any errors in the console?