how to use usedispatch in javascript code example Example: useDispatch() useDispatch({ type: '', playload });