1

I have a input box, when I click on it I'll actually send the eventdata of the input box using a function:

<input type="text" (click)="show($event)"/>

I'm using typescript here to write a function hence I need to assign a type to the function parameter

What will be the type for an event?

Typescript Code :

show(eventdata: ?) { }
indexoutofbounds
  • 793
  • 12
  • 32
Harish
  • 1,193
  • 6
  • 22
  • 45

1 Answers1

2

Well as you are catching a click in your input element, the event will most propbably be of the type MouseEvent.

You also might want to have a look at this answer.

indexoutofbounds
  • 793
  • 12
  • 32