StephenGrider/ReactSSRCasts

Url with param

Opened this issue · 0 comments

KchTT commented

Hi!
Im trying to add the user id in the url..like /users/1
I put 'user/:id' router´s file but the problem is that when i call the component with props it render twice.
'const UserPanel = (props) => {'

at first render get de props.params.id { id: 1 }
next render get { id: 'bundle.js' }

Do you know what may be happening?
Thanks a lot! your courses are very clear...