-
Notifications
You must be signed in to change notification settings - Fork 422
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Injection happen after page load #1475
Comments
I noticed it too, and actually had a really nasty piece of code waiting for a sec or 2 before checking again when I handled the connection myself. I've had a user tell me the same on Multix while using dot-connect. I believe it's safer for pjs extension to do so, and I guess dot-connect could probably poll for a couple seconds. |
Yeah, polling or delaying is an easy fix. But ideally this should be fixed on PJS extension side, since this is an unexpected behaviour that is unique to PJS extension. |
I guess it comes from there:
it waits for the document to be in "complete" state. I wonder if we should have document.readyState === "loading" .In early code we were injecting in either state complete or interactive , now it rang a bell, and I do recall we had issues explaining why we went for the safer side, I found the comment: #507 (comment)
|
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue if you think you have a related problem or query. |
Since injection happen asynchronously after the page have loaded, if you try to detect whether PJS is installed too early, it might appeared that the extension is not installed.
The text was updated successfully, but these errors were encountered: