reload method

Future<void> reload({
  1. bool? ignoreCache,
  2. String? scriptToEvaluateOnLoad,
})

Reloads given page optionally ignoring the cache. ignoreCache If true, browser cache is ignored (as if the user pressed Shift+refresh). scriptToEvaluateOnLoad If set, the script will be injected into all frames of the inspected page after reload. Argument will be ignored if reloading dataURL origin.

Implementation

Future<void> reload(
    {bool? ignoreCache, String? scriptToEvaluateOnLoad}) async {
  await _client.send('Page.reload', {
    if (ignoreCache != null) 'ignoreCache': ignoreCache,
    if (scriptToEvaluateOnLoad != null)
      'scriptToEvaluateOnLoad': scriptToEvaluateOnLoad,
  });
}