dispose method Null safety

Future<void> dispose()

Disposes the headless WebView.

Implementation

Future<void> dispose() async {
  if (!_running) {
    return;
  }
  Map<String, dynamic> args = <String, dynamic>{};
  await _channel.invokeMethod('dispose', args);
  _started = false;
  _running = false;
}