mardi 27 janvier 2015

What is the performance penalty of using SVGs on a page?

I have a company logo that is in vector format. I've noticed that some websites use the SVG format to render their logos, versus the more traditional PNG format.


Does this have a performance cost? If page load time is all I care about, should I continue to use raster images?


Things that I imagine could make SVGs slower:



  • SVG renderer not loaded in browser by default, so first SVG that shows up on a page requires it to load a library.

  • Rasterizing is slow.

  • Raster image may not be cached

  • Not common so maybe less optimized that other image rendering in general

  • Beyond rasterization issues, SVGs have a lot of other functionality and probably comes with a perf cost vs blitting out a pic.





Aucun commentaire:

Enregistrer un commentaire