Edit this page

up.layer up.layer.on(types, [selector], [options], listener)
JavaScript function

Listens to a DOM event that originated on an element contained by the current layer.

This is a shortcut for up.layer.current.on(). See up.Layer#on() for more documentation.


Parameters

types string

A space-separated list of event types to bind to.

[selector] stringorFunction(): string optional

The selector of an element on which the event must be triggered.

[options] Object optional
listener Function(event, [element], [data])

The listener function that should be called.

Return value

Function()

A function that unbinds the event listeners when called.