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

preconnect to storage bucket #1462

Open
SamuelmdLow opened this issue May 20, 2024 · 2 comments
Open

preconnect to storage bucket #1462

SamuelmdLow opened this issue May 20, 2024 · 2 comments
Assignees

Comments

@SamuelmdLow
Copy link
Member

Adding this link element in the head of base.html might make the page load ever so slightly quicker

https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/rel/preconnect

@Nishim12 Nishim12 self-assigned this May 28, 2024
@Nishim12
Copy link
Contributor

Nishim12 commented May 28, 2024

We can also use dns-prefetch for loading some other 3rd party websites instead of pre-connect in some places in base.html file as using too many pre-connects can be counter-productive.
https://developer.mozilla.org/en-US/docs/Web/Performance/dns-prefetch

@Nishim12
Copy link
Contributor

By testing preconnecting and dns-prefetching different 3rd party API such as JQuery, Google ads, Font Awesome, Google APIs, twitter, bootstrap I realized that its faster if we dont pre-connect or prefetch. Tested using Google Lighthouse, Google network and Django build in functionality that gives us load time. I tried many different combinations such as not using many pre-connects as that slows the speed of load time. Also tried using dns-pretching as fallback option. So I am keeping the website as it is right now as on average that gave the best result.

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

When branches are created from issues, their pull requests are automatically linked.

2 participants