title: window.open() in Angular 4.4.6 Resolver
body: <p>I have a task to implement opening a url in a different tab when clicking on an item in a dropdown menu using Angular 4.4.6
  I have a hack solution using a dummy component with a window.open() method to get the job done. But I tend to think there is a more elegant solution to this. Tried a hack using a derivative of <a href="https://stackoverflow.com/questions/40150393/how-to-redirect-to-an-external-url-from-angular2-route-without-using-component">this</a> answer, which I believe is close, but I'm missing something. 
  Here is a snippet of what I am trying:</p>
  
  <p>app.module.ts provider excerpt of Resolver</p>
  
  <pre><code>    {
          provide: 'urlRedirectResolver', useValue: (route: ActivatedRouteSnapshot, state: RouterStateSnapshot) =&gt; {
              //Something like this
              window.open((route.data as any).otherUrl);
              //OR
              window.location.href = window.open((route.data as any).otherUrl); 
          }
      }
  </code></pre>
  
  <p>app.router.ts route excerpt of Implementation</p>
  
  <pre><code>    path: 'SomeComponentURL', component: SomeComponent, resolve: {
          url: 'urlRedirectResolver'
      },
      data: {
          otherUrl: (document.location.hash != '#/SomeComponent')
              ? 'someContent.pdf' : history.back()
      }
  </code></pre>
  
  <p>If the question is too vague please let me know and I'll try to revise it. Any help is greatly appreciated!</p>