getBackgroundPage method

JSObject? getBackgroundPage()

Returns the JavaScript 'window' object for the background page running inside the current extension. Returns null if the extension has no background page.

Implementation

JSObject? getBackgroundPage() {
  return $js.chrome.extension.getBackgroundPage();
}