In the new Angular2 framework, does anyone know the proper way to do a hover like an event?
In Angular1 there was ng-Mouseov
Simply do (mouseenter) attribute in Angular2+...
In your HTML do:
Hover!
and in your component do:
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'component',
templateUrl: './component.html',
styleUrls: ['./component.scss']
})
export class MyComponent implements OnInit {
mouseHover(e) {
console.log('hovered', e);
}
}