'react admin refresh pass payload
I have some custom logic in react admin comonent (actually try to implement DatePicker). So i need to use useRefresh and pass some payload inside. But something goes wrong(it seems that useRefresh do not accept any arguments). How could i achieve this?
for simplify logic below is simple code:
const refresh = useRefresh()
<Button onClick={()=>{myFunc(start_date, end_date)}}>
const myFunc = (start_date, end_date) => {
refresh ({filter:{start_date:start_date, end_date:end_date}}) // Could i pass variables inside refresh() or how i could achive this ?
}
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
