Open pradeep910 opened 1 year ago
Hi @pradeep910, I checked this issue on local and identified that,
text/rtscript-noautoload
to the script and further with intersection observer as wrapper for blockqoute
embed. youtube
as per this comment. Further, I have added an array in which we can add which iframe we want to lazy load in the PR #29. This PR adds the lazy loads to embed video such as vimeo
and dailymotion
. Thanks.
Verified the Lazy load for the embeds added here. It is working fine. It is loading on the scroll. Just the facebook embed is not possible so that not able to verify. Rest all other embeds are working fine.
cc: @pradeep910 @hbhalodia
Thanks @pavanpatil1, I have raised PR for the main branch - https://github.com/rtCamp/rt-optimizer/pull/31
The default youtube codes are loaded all at once. Making it load youtube scripts on page load.
Making it lazyload will reduce performance impact at the time of loading.
Handle above the fold embeds/iframe differently because it needs to be loaded asap, whereas below the elements can be lazyloaded.
and so on..