Open bfbachmann opened 5 years ago
You'll need to update App.js
by adding a route that allows you to get to the ViewUser component:
<Route path='/users/:username' component={this.getViewUserPage} />
You'll also have to add a getViewUserPage
method to App.js
that returns a ViewUser
component that is initialized with the user's username:
getViewUserPage(filter) {
const username = decodeURIComponent(filter.match.params.username);
return <ViewUser
client={this.props.client}
username={username}
/>;
}
You'll need to create a new component called
ViewUser.js
. See https://reactjs.org/tutorial/tutorial.html for a tutorial.