onPressIn( )


Adds an event handler that runs immediately when an element on a mobile app is pressed.

A mobile element receives an event immediately when a mobile app user presses on the element. The onPressIn() function runs before the onPress() and onLongPress() functions.

Method Declaration
Copy
Method Parameters
handlerfunctionRequired

handler(): void The name of the function or the function expression to run when an element on a mobile app is pressed.

Returns
Return Type:MobileElement
Was this helpful?
Yes
No