mirror of
https://github.com/hensm/fx_cast.git
synced 2026-06-11 10:09:59 +00:00
Fix webcomponents polyfill loading
This commit is contained in:
@@ -1,6 +1,19 @@
|
||||
"use strict";
|
||||
|
||||
import { onMessageResponse, sendMessage } from "./eventMessageChannel";
|
||||
import { loadScript } from "../lib/utils";
|
||||
|
||||
|
||||
const { isFramework }
|
||||
: { isFramework: boolean } = (window as any);
|
||||
|
||||
/**
|
||||
* Framework API library requires webcomponents for the cast
|
||||
* button custom element (<google-cast-launcher>).
|
||||
*/
|
||||
if (isFramework) {
|
||||
loadScript(browser.runtime.getURL("vendor/webcomponents-lite.js"));
|
||||
}
|
||||
|
||||
|
||||
// Message port to background script
|
||||
|
||||
Reference in New Issue
Block a user