serversideup / webext-bridge

💬 Messaging in Web Extensions made easy. Batteries included.
https://serversideup.net/open-source/webext-bridge
MIT License
547 stars 50 forks source link

Back navigation breaks communication in Safari #42

Open Benjadahl opened 2 years ago

Benjadahl commented 2 years ago

Hi,

We are using webext-bridge to create a cross platform extension deployed to Chrome and Safari on Mac and iOS. We found an issue that occurs when using the back button, but only on Safari. When navigating back, sometimes following sendMessage requests will never resolve. (Using the native chrome.runtime API does resolve correctly). We tried to use the webext-bridge@6.0.0-rc3 release instead - it seemed to improve the succes rate from 0% to about 50%, however it still has issues.

Would you like for us to provide a repository reproducing the issue? And is there any way else that we can contribute to fixing the issue?

Thanks a lot

zikaari commented 2 years ago

What browsers have you confirmed webext-bridge@6.0.0-rc3 to be working correctly?

Benjadahl commented 2 years ago

According to our tests:

zikaari commented 2 years ago

Safari is something I don't have expertise in, so unfortunately I won't be able to help code wise. Please see if you can find a solution, a PR would be very welcome.

Benjadahl commented 2 years ago

Alright, we'll take a look tomorrow. Do you have any idea where in the code, it might be relevant for us to search?