After executing "chrome.runtime.sendMessage()" in content.js, sometimes "chrome.runtime.onMessage.addListener()" in event.js may not fired.
Immediately after starting the Chrome browser, the process works normally, but after a certain period of time, this phenomenon seems to occur.
If you are experiencing the same phenomenon and someone has solved the problem, please tell me how to solve it.
[content.js]
chrome.runtime.sendMessage(message,function(response){
:
}
[event.js]
chrome.runtime.onMessage.addListener(function(message, sender, sendResponse) {
:
}
[manifest.json]
:
"background":{
"scripts": [
"event.js"
],
"persistent": false
},
:
Best Regards,