I have issue with chrome extension in manifest v3. Usually reproduce on MacOS. Before migrating to manifest v3 my app was on manifest v2 and I did't have this problems. Some times app is not reacting on click at icon of list extensions. So I need to reload computer or disabled the app and after turn on it to resolve this problem. In console i have errors: "Could not establish connection. Receiving end does not exist.", "ResizeObserver loop limit exceeded", "Request failed with status code 403". Or without any errors in console. It seems like service worker don't start again or stuck in the loop
"background": {
"service_worker": "js/background.js",
"type": "module"
},
"content_scripts": [{
"matches": ["<all_urls>"],
"js": [
"js/contentscript.js"
]
}],
this is code from manifest
chrome.runtime.onMessage.addListener((message, sender, sendResponse) => Promise.resolve()
.then(() => { sendResponse(); })
.then(() => {
if (message === 'toggle-popup') {
updateApplicationTab((idTab) => {
chrome.tabs.sendMessage(idTab, { message: 'clicked_browser_action' });
});
}
if (message === 'toggle-popup_set_id') {
chrome.tabs.query({ active: true, currentWindow: true }, tabs => {
chrome.runtime.sendMessage({
type: 'setActiveTab',
data: tabs[0].id,
});
});
}
}),
);
this is code from worker to open app