openBrowser method

dynamic openBrowser(
  1. String url,
  2. String redirectUrl, [
  3. bool isTestMode = false
])

Opens browser with URL returned from startTransaction()

Implementation

openBrowser(final String url, final String redirectUrl,
    [final bool isTestMode = false]) async {
  final FlutterwaveInAppBrowser browser =
      FlutterwaveInAppBrowser(callBack: _callBack);

  var options = InAppBrowserClassOptions(
    crossPlatform: InAppBrowserOptions(hideUrlBar: true),
    inAppWebViewGroupOptions: InAppWebViewGroupOptions(
      crossPlatform: InAppWebViewOptions(javaScriptEnabled: true),
    ),
  );

  await browser.openUrlRequest(
      urlRequest: URLRequest(url: Uri.parse(url)), options: options);
}