Search code examples
materializelighthouse

how to resolve displaying images with inappropriate size for data:image/gif;base64


I have noticed that lighthouse is saying the I am displays images with inappropriate size for data:image/gif;base64, this iamge is generated by Materialize slider and its giving a displayed size of 381x655 an actual size 1x1 and an expected size 1143 x 1965, I can see that lighouse explains how to resolve this issue with the original image but I can not find out how to resovle this issue for a data:image/gif;base64 generated image by Materialize I mean is it a setting in jquery or css or is there some other method ?


Solution

  • looking at your question I guess the solution is

    <img srcset="image_1143x1965.jpg 2x, image_381x655.jpg 1x" src="image_default.jpg" />
    
    
                
    

    an explanation of this can be found at https://html.com/attributes/img-srcset/