Using an image file vs data URI in the CSS

Posted by fudgey on Stack Overflow See other posts from Stack Overflow or by fudgey
Published on 2009-09-24T03:12:37Z Indexed on 2010/04/23 11:03 UTC
Read the original article Hit count: 286

Filed under:
|
|

I'm trying to decide the best way to include an image that is required for a script I've written.

I discovered this site and it made me think about trying this method to include the image as a data URI since it was so small - it's a 1x1 pixel 50% opacity png file (used for a background) - it ends up at 2,792 bytes as an image versus 3,746 bytes as text in the CSS.

So would this be considered good practice, or would it just clutter up the CSS unnecessarily?

© Stack Overflow or respective owner

Related posts about css

Related posts about images