score:1

Accepted answer
<VisitorOnlyRoute path="/register" exact component={Register} />

score:0

/* In your `Login` component */
function doLogin() {
    somehowSendLoginApiRequest().((response) => {
        if (response.ok) {
            this.props.history.push('/dashboard');
        }
    });
}

Related Query

More Query from same tag