I am new to redux, I created a route to navigate to user edit page and i also want to pass store and history as props using the code below.
<Route path="/edit/:id" render={({history}) => (
<EditUser store={store} history={history} />
)}/>
But now i cannot access the params which i am passing (:id) in my EditUser component. When i try to access using this.props.match.params.id, it shows undefined, but it works if i rewrite my route to
<Route path="/edit/:id" component={EditUser}/>
But now i think case i am not able to pass other props.
Help much appreciated.
<Route>are you using<BrowserRouter>, share your index.js?