Skip to content
Discussion options

You must be logged in to vote

Actually the suggested plugin didn't work for me, as the layout was still shifting and it had issues downloading many small files. So i've made a vite plugin that downloads remote media (images and video) assets, resolves their size and injects the width and height to the <img> and <video> tags, so that the layout doesn't shift at all when loading pages.

Here is the plugin: https://github.com/elringus/imgit

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@elringus
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by elringus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants