iannotian / BigBisonChat-React

React client for BigBisonChat
https://chat.bigbison.co
0 stars 0 forks source link

Use withRouter instead of LinkButton (which uses Context API) to route to new conversation after creating one #5

Closed iannotian closed 5 years ago

iannotian commented 5 years ago

Should not use LinkButton custom component. React Router v4 supplies a withRouter method to supply the Create Chat button with a route to point to.

See: https://stackoverflow.com/questions/31079081/programmatically-navigate-using-react-router

iannotian commented 5 years ago

Did not end up requiring withRouter; used props.history.push(PATH) as supplied by React Router.