It's quite common to redirect a user visiting your webpage, more specifically when they perform an action, such as: clicking a button. When the user completes the action and you want to redirect the user to somewhere else, you have two common choices:
window.location.href = '';


OR
window.location.replace('');