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

Add lazy loading and async decoding to images #177

Open
lb- opened this issue May 26, 2022 · 5 comments
Open

Add lazy loading and async decoding to images #177

lb- opened this issue May 26, 2022 · 5 comments
Labels
good first issue Good for newcomers

Comments

@lb-
Copy link
Member

lb- commented May 26, 2022

Overview

  • To speed up the loading experience in Wagtail docs, it would be good to adopt two img tag features loading='lazy' and decoding='async'.

Details

@lb- lb- added the good first issue Good for newcomers label Sep 22, 2022
@mohammadareeb95
Copy link
Contributor

I'm starting to work on this issue

@lb-
Copy link
Member Author

lb- commented Oct 14, 2022

Awesome

@lb-
Copy link
Member Author

lb- commented Oct 16, 2022

Some nuance here - only images that are non-critical to the Docs interface should be lazily loaded.

Example - tutorial screenshots about clicking a button in the admin interface - this can be lazy.
Example - core logo for the header - this should not be lazy & show straight away.

I am not sure how we will do this yet, my guess is it will be something at the myst-parser or sphinx config level.

Maybe google 'Sphinx default image attributes lazy load' or 'myst-parser default image attributes' or something like that.

@mohammadareeb95

@mohammadareeb95
Copy link
Contributor

@lb- Thanks for the context, I'm trying to figure this out.

@lb-
Copy link
Member Author

lb- commented Oct 18, 2022

Some research, a lot of this is new to me also

Note: This may end up being one of those things that we have to solve in the theme here and also on the Wagtail usage of the theme if it's a config thing.

Anyway - those links could be a dead end but hopefully that helps.

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

No branches or pull requests

2 participants