Skip to content
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

Requesting support for firefox #262

Open
adrianvanburen opened this issue Jun 2, 2022 · 3 comments
Open

Requesting support for firefox #262

adrianvanburen opened this issue Jun 2, 2022 · 3 comments

Comments

@adrianvanburen
Copy link

adrianvanburen commented Jun 2, 2022

Is your feature request related to a problem? Please describe.

I just tested this script on my wordpress site ( https://www.lyka.stream/ ) and it works only in chrome; would it be possible to support firefox since it seems to support prefetching? See: https://caniuse.com/link-rel-prefetch

Additional context
Firefox:
Capture d’écran 2022-06-02 à 17 19 39
Chrome:
Capture d’écran 2022-06-02 à 17 20 55

As you see, chrome works ideally, but firefox does not work

I am using Firefox version 101

@pereorga
Copy link

pereorga commented Aug 4, 2022

This may be related to a Firefox bug: links not being prefeched in Firefox in some circumstances: https://bugzilla.mozilla.org/show_bug.cgi?id=1783225

@kronthto
Copy link

kronthto commented Mar 22, 2023

We can also notice this behaviour: The link tags get added to the Head by the JS of this lib, but no requests are happening.
I've found a few resources claiming that Firefox only respects rel="prefetch" tags that were there when the document was loaded, not dynamically injected:

As a workaround, if the user-agent indicates Firefox, the XHR method could be used instead?

@adrianvanburen
Copy link
Author

@kronthto I later got to the bottom of it, I learned while Firefox supports prefetch, this behaviour is disabled by default. You have to go into the advanced settings to activate it, then this script begins to work. Unfortunately this means we have no workaround for delivering it to all Firefox users yet.

gijo-varghese/flying-pages#14 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants