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

fix(gatsby-plugin-netlify): add page-data & app-data to preload list #21552

Merged
merged 4 commits into from
Feb 25, 2020

Conversation

wardpeet
Copy link
Contributor

@wardpeet wardpeet commented Feb 18, 2020

Description

Improve netlify headers by adding page-data & app-data to HTTP preload, this will let the browser start the download sooner.

It works :) You can see the difference in these snapshots, the important part is when our images start to load. As these are our indicators when our js is being executed.

Mobile 4G:
https://webpagetest.org/video/compare.php?tests=200224_T2_3323f0e578a9efc861f44ddcd2bd4250%2C200224_F2_68e33c289ced2e9c826d9617f4e8f18a&thumbSize=200&ival=100&end=full

Desktop 4G:
https://webpagetest.org/video/compare.php?tests=200224_DW_f3516a43d45095def0edab713dd22f73%2C200224_8C_75beb58838faed97672a522b7b21458b&thumbSize=200&ival=100&end=full

Desktop fast internet:
https://webpagetest.org/video/compare.php?tests=200224_MV_a147387f2c846b1685f05bc407ef5ac7%2C200224_MT_d1b109458f8135fde63248ed82b20f1a&thumbSize=200&ival=100&end=full

@blainekasten
Copy link
Contributor

Does this config option affect this? https://www.gatsbyjs.org/docs/browser-apis/#disableCorePrefetching

@wardpeet wardpeet closed this Feb 24, 2020
@wardpeet wardpeet deleted the fix/netlify-preload-header branch February 24, 2020 08:17
@wardpeet wardpeet restored the fix/netlify-preload-header branch February 24, 2020 09:10
@wardpeet
Copy link
Contributor Author

Oh damn I closed this one

@wardpeet wardpeet reopened this Feb 24, 2020
@wardpeet wardpeet marked this pull request as ready for review February 24, 2020 11:15
@wardpeet wardpeet requested a review from a team as a code owner February 24, 2020 11:15
@wardpeet
Copy link
Contributor Author

I removed the no-push changes I made earlier as they are not needed and make this PR more complex

Copy link
Contributor

@pieh pieh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! 🚢 it!

@pieh pieh merged commit bf3fabd into gatsbyjs:master Feb 25, 2020
@wardpeet wardpeet deleted the fix/netlify-preload-header branch September 23, 2020 18:50
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

Successfully merging this pull request may close these issues.

3 participants