Hello, I'm starting to work with React and I'm doing an integration with Firebase. My problem is this, I can already trigger all the actions I need, but when I fire my last action from USUARIO_ENTRAR_SUCESSO
I need to react-router-dom
navigate to the /:uid
route.
My reducer looks like this:
export const usuarioReducer = (state = initialState, action) => {
switch(action.type) {
// ...outras actions...
case 'USUARIO_ENTRAR_SUCESSO': {
// preciso navegar quando essa action for disparada
return state;
}
default:
return state;
}
}
How do I do this?