WebOlution

Web Design & Marketing

5.0 (1 Reviews)
About WebOlution
WebOlution is a web design company in Athens Greece. Our passion is to make simple, beautiful, modern sites for you. We specialise in web marketing and in the development of web sites as well as with their further optimisation for search engines.
$50 - $99/hr
2 - 9
2004
Greece
WebOlution
Web Design & Marketing
5.0 (1 Reviews)
1 Review
Client Reviews
A great website developed and designed
Elia Mykonos Owner at Elia Beach Hotel & Restaurant
on 1/4/20
Quality of deliverable
Customer support
Value for money
Overall rating
Project Details
Project Name
A great website developed and designed
Services:
Web Development
Project Status:
Completed
Services

Web Design, Web Development, Apps Development, Web Marketing, SEO, and CRM.

Focus
Service Focus
Discussions
  • CSS
  • JavaScript
1 Answer
You should actually avoid doing this using CSS or JavaScript. I will explain to you why.When the browser starts loading a page, it starts preloading all the images before the loading of the main parser and the interpretation of the page’s CSS and JavaScript. In general, that mechanism seems useful to reduce page-loading times, but it does not help with the responsive images. Hence, you have to create a solution in this case like ‘srcset’. For example, you could not load the ‘img’ element, then detect the viewport using JavaScript, and then make the dynamic changes to the source image to a smaller one if needed. By then, the original image would have already been loaded, and you will attempt to load the small image as well, which is even destructive in terms of a responsive image.  
You should actually avoid doing this using CSS or JavaScript. I will explain to you why.When the browser starts loading a page, it starts preloading all the images before the loading of the main parser and the interpretation of the page’s CSS and JavaScript. In general, that mechanism seems useful to reduce page-loading times, but it does not help with the responsive images. Hence, you have to create a solution in this case like ‘srcset’. For example, you could not load the ‘img’ element, then detect the viewport using JavaScript, and then make the dynamic changes to the source image to a smaller one if needed. By then, the original image would have already been loaded, and you will attempt to load the small image as well, which is even destructive in terms of a responsive image.  

You should actually avoid doing this using CSS or JavaScript. I will explain to you why.

When the browser starts loading a page, it starts preloading all the images before the loading of the main parser and the interpretation of the page’s CSS and JavaScript. In general, that mechanism seems useful to reduce page-loading times, but it does not help with the responsive images. Hence, you have to create a solution in this case like ‘srcset’. For example, you could not load the ‘img’ element, then detect the viewport using JavaScript, and then make the dynamic changes to the source image to a smaller one if needed. By then, the original image would have already been loaded, and you will attempt to load the small image as well, which is even destructive in terms of a responsive image.  

Contact information
gr
WebOlution
14-18, Karea Street, Mets, Athens, Attica 11636
Greece
302107564325