Issue with nesting the routes #6
Comments
Not sure just yet if this is a problem with the starter kit or react-router or some combination, but I've reproduced it and am looking into it. Going to link to your issue on react-router while this is troubleshooted: remix-run/react-router#1682 ... seems like it might be a problem with their 1.0.0 version, as there are a few related issues open in their repo. |
@davezuko , yeah i guess so. I think ill try to replace current router with 0.13 and try to work with it until it will be resolved. Thank you :) |
@zoilorys Ok, hopefully that works. I experimented with removing the Going to leave this ticket open in the meantime in case someone happens to have an idea. |
@davezuko , ok, thanks again) Yeah i will post here if swapping router version helps, then i guess it will be obvious whats the problem. |
@zoilorys I changed the history that's passed to the Router from In the starter-kit, this is in This is my route structure
Then: // views/user/profile/index.jsx
import React from 'react';
export default class ProfileView extends React.Component {
constructor () {
super();
}
render () {
return (
<div>
<h2>Profile {this.props.params.id}!</h2>
</div>
);
}
}
// views/user/index.jsx
import React from 'react';
export default class UserView extends React.Component {
constructor () {
super();
}
render () {
return (
<div>
<h1>User View!</h1>
{this.props.children}
</div>
);
}
} |
Also might want to check this out: remix-run/react-router#676 |
@zoilorys sorry for the spam lol, but I just added a // ~/build/webpack/client/index.js
const config = makeConfig({
name : 'Client',
target : 'web',
entry : {
app : [
projectConfig.inSrc('entry-points/client')
],
vendor : projectConfig.VENDOR_DEPENDENCIES
},
output : {
filename : '[name].[hash].js',
path : projectConfig.inDist('client'),
publicPath : '/' // ADD THIS
}
}); |
Merge pull request #4 from davezuko/master
Playing around with kit. I got this setup for routes :
Nested routes like 'user/:id' , or even without params, just 'user/profile' doesn't work - error 404 =\
Tried different types of nesting, even without path with '/', like
, nothing works... Read through 1.0.0-beta3 docs many times, it seems like i'm doing everything right - but it doesn't work.
Can anyone figure out whats the problem?
Wrapping component UsersView renders {this.props.children}.
The text was updated successfully, but these errors were encountered: