I want to call [scrollIntoView](https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoView) on a HTML element in a component.

In angular.js 1 I can do something like this in the controller:

```
var element = $window.document.getElementById(id);
element.scrollIntoView({ behavior: "smooth", block: "start" });

```

How can I do the same thing in angular 2+ ?