0

how to set static url in angular4 routing. this.router.navigate('https://xxxxxx.com/abx/xyz') like this , Which means i want to navigate to another website from my angular application.

Samudrala Ramu
  • 2,008
  • 1
  • 13
  • 35

2 Answers2

0

You can use window.location.href = '...';

Varun Sukheja
  • 5,187
  • 4
  • 39
  • 78
  • i added but i have a doubt, in my Project Redirect to is there so it'll override my window.location.href? – Samudrala Ramu just now – Samudrala Ramu Jul 24 '19 at 11:22
0

Use this code to redirect to external link

window.location.href = "url";
Tony Ngo
  • 17,297
  • 4
  • 29
  • 55