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

Annoying flash of images on first page load #34

Closed
WhiteHoodHacker opened this issue Mar 24, 2023 · 3 comments
Closed

Annoying flash of images on first page load #34

WhiteHoodHacker opened this issue Mar 24, 2023 · 3 comments
Milestone

Comments

@WhiteHoodHacker
Copy link
Member

After first loading the home page, images will first appear as blur placeholders, then eventually the actual images will load one-by-one. However, after this happens, all the images briefly disappear so a flash occurs. Confirmed issue on Chrome/Firefox. Possibly related to rehydration or Gatsby's image plugin.

@WhiteHoodHacker
Copy link
Member Author

Closed in favor of #52

@WhiteHoodHacker
Copy link
Member Author

I can't replicate this on a local server, so maybe it has something to do with Cloudflare Pages?

@WhiteHoodHacker
Copy link
Member Author

This was a pain to debug. The console errors indicated that this was a React hydration issue where the HTML on the client doesn't match what React renders. However, this issue only appeared on beta.sigpwny.com - not on any development server, GitHub Pages, or even sigpwny-com.pages.dev. Auto minify was already disabled on Cloudflare Pages. It turns out the issue was DNS 🥲. Specifically, Cloudflare's DNS proxy:

image

I guess enabling that adds some extra minification/processing to the transferred site content? Anyways, disabling that fixed the issue.

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

1 participant