The simplest way to make a redirect is by using window object (window.location.href):
window.location.href = 'http://mysite.com';
You also can use window.location.assign or window.location.replace:
window.location.assign( 'http://mysite.com' ); window.location.replace( 'http://mysite.com' );
While window.location.assign acts just like window.location.href, window.location.replace doesn't store original page in browser history.