I want that my chrome extension sidebar opens automatically, when the URL contains meet.google.com. Can someone point me to the errors in my code?
chrome.runtime.onInstalled.addListener(function () {
// Set up the event listener for webNavigation
chrome.webNavigation.onCompleted.addListener(function (details) {
// Check if the URL is "https://meet.google.com/"
if (details.url === "https://meet.google.com") {
// Open the extension popup
chrome.tabs.query({ active: true, currentWindow: true }, function (tabs) {
chrome.scripting.executeScript({
target: { tabId: tabs[0].id },
func: openIframeSidebarOnGoogleMeet,
});
});
}
});
});
// Function to be executed in the context of the page
function openIframeSidebarOnGoogleMeet() {
// Call your function to open the sidebar
openIframeSidebar("https://standbyclone.bubbleapps.io/meetings", "400px");
}