Answer the question
In order to leave comments, you need to log in
React Route (render, children) not working why?
Hello.
For some reason, the react route does not want to work, namely render, children.
I look at everything from the documentation, but it does not plow.
Please tell me what is the problem?
render(){
return (
<Router>
<Routes>
<Route exact path="/users" render={() => <div>Home</div>}/>
</Routes>
</Router>
)
}
Answer the question
In order to leave comments, you need to log in
What version of the router? In 6 there is no render prop, there is an element
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question