addEventListener method
Add a new event listener to the device.
Marking the method with JSUtils.allowInterop
will be done automatically
for you.
Events to be handled are:
- oncharacteristicvaluechanged
See:
Implementation
void addEventListener(
final String type, final void Function(dynamic) listener) {
_JSUtil.callMethod(
_jsObject, "addEventListener", [type, _JSUtil.allowInterop(listener)]);
}