setOnShowCallback static method

Future<void> setOnShowCallback(
  1. Function function
)

Sets a block of code to be executed just before the SDK's UI is presented. This block is executed on the UI thread. Could be used for performing any UI changes before the survey's UI is shown. function A callback that gets executed before presenting the survey's UI.

Implementation

static Future<void> setOnShowCallback(Function function) async {
  _channel.setMethodCallHandler(_handleMethod);
  _onShowCallback = function;
  await _channel.invokeMethod<Object>('setOnShowSurveyCallback');
}