JavaScript Image Optimiser (JSIO)

So, I’ve embarked on a new mini project. It is kind of inspired by image sprites.

Image sprites are a great idea, but come with a whole bunch of issues that make them a bit of a pain to work with.

Firstly, most of the time you have to use markup to create an element in html to “hold” the image you wanted to display from your sprite. This is because if you actually set a sprite as the background image for a large html element you’re likely to see other images in the sprite as well. Because of this, you actually lose useful functionality that CSS gives you, like the ability to position, repeat and scale an image. Also, the markup you’ve created to hold the image exists for style purposes, which is bad.

Secondly, sprites can be a massive ball ache to maintain. If you’ve closely packed your images in a sprite for maximum efficiency and then one of your images needs to change size, you’re either going to have to move ALL images surrounding the image you have to update (and obviously then change all background-position properties for the images you’ve moved) or leave a space and put the updated image in a new position in your sprite.

How do you know which images in a sprite are used and which ones are dead? Since your images are referenced by coordinates, this sort of clean up becomes a nightmare and is actually a bit lot of a nightmare to create image sprites in the first place.

The goals of the project are to

  1. Reduce the number of http requests (and their associated header traffic) to the server and hence reduce the time it takes to load all images on a website and bandwidth footprint the site requires
  2. Create a solution that’ll alleviate some of the problems surrounding the creation and use of image sprites
  3. Do something cool

The JSIO project website has a pretty good explanation of how it works so I won’t bore you with the details here. However, as a brief overview, it packages all your image data in data uri format and you reference particular images by their filename rather than their coordinates.

The site actually uses the HTML5 file api to generate your resources file for you, which makes creating and maintaining your JSIO “sprite” really really easy.

I read *somewhere* that data uri encoded images can be up to 1/3 larger than corresponding image files, however with gzip encoding they can be only 0-3% larger (or less). My thesis is that for a site with many small images, JSIO could be more efficient and easier to maintain than having separate files or even an image sprite.

…I’m yet to prove or disprove this and I’ll be conducting some tests whose results I’ll post up here (even if they do prove JSIO to be useless).

Disclaimer: This is the first ever ALPHA release of JSIO – it works on the latest Firefox and Chrome but I haven’t even checked it in IE yet. It probably won’t work in IE yet. Also, the website needs some work for optimal display on mobile devices.

17,027 thoughts on “JavaScript Image Optimiser (JSIO)”

  1. Катадолон и алкоголь совместимость купить Героин Кокаин Экстази Челябинск купить закладку Cocaine Premium: Peru Купить закладку скорость Сафрол Туран купить Метадон VHQ https://loft-u.ru Моршанск купить VHQ Cocaine 98 Bolivia Купить lsd в Катав-Ивановск купить Мефедрон Кокаин Бошки Марихуану Гашиш Марихуана и конопля разница

  2. slot masine free casino mulino slovenia casino slot free hit holidays kranjska gora casino Ocena najboljsih spletnih igralnic What time do slots hit the most gday casino no deposit bonus codes 2026 live roulette online casino

  3. igre casino book of ra nagradne igre casino Igralni avtomati ki jih lahko igrate brezplacno live casino tracker

  4. Инсбрук купить закладку Марихуана KUSH купить Героин Кокаин Экстази Голицыно купить закладку DMT Купить закладку скорость Пушкино купить закладку Cocaine MQ Челябинск купить Mephedrone 4mmc мяу https://art-melodika.ru Ленинградская область купить Мефедрон елкие камни/мука HQ Москва Текстильщики купить закладку Метамфетамин купить Мефедрон Кокаин Бошки Марихуану Гашиш Эйлат купить Амфетамин

  5. mansion online casino hotel casino admiral kozina Igralni avtomati ki jih lahko igrate brezplacno casino rewards vip

  6. Безупречное техническое состояние автомобиля — залог вашей безопасности и комфорта на любой дороге. Специализированный современный техцентр https://lemon-car.ru/ оказывает полный комплекс профессиональных услуг в Анапе: от детальной компьютерной диагностики и ТО до сложного агрегатного ремонта и качественного детейлинга. Доверьте заботу о вашей машине опытным мастерам высшей квалификации.

  7. lucky lady casino online kako delujejo spletni avtomati za pravi denar casino bled park hotel slot game free casino 3888 Avtomati za zabavo brez denarja casino igre pol-o-slot omni casino no deposit bonus hit kranjska gora casino kontakt

  8. free games casino no deposit casino bonus 50 euro Obiscite slovensko spletno igralnico blackjack online casino

  9. Когалым купить Мефедрон елкие камни/мука HQ купить Героин Кокаин Экстази Верхняя Салда купить наркотики Купить закладку скорость Купить Марки Сенгилей Искитим купить Гашиш Cube https://boshkionline.shop Котлас купить закладку Марихуана Scout Cookies купить закладку в АрмянскОспаривается купить Мефедрон Кокаин Бошки Марихуану Гашиш Тимашёвск купить Ecstasy

  10. live casino 2026 bet 365 restricted account Еѕrebanje eurojackpot ura games similair to book of ra deluxe Bonus brez vplacila blackjack demo pragmatic casino admiral kozina bet 365 singup bonus

  11. online casino game platinum reels no deposit bonus Igralnica na spletu za pravi denar casino igre gratis

  12. Купить Гиблый Элиста купить Героин Кокаин Экстази Исилькуль купить Амфетамин Купить закладку скорость Апшеронск купить закладку Марихуана Haze Нязепетровск купить LSD-25 в марках 250мк https://happy-sad.ru Кольчугино купить Мефедрон 2.0 Северо-Курильск купить закладку Мефедрон в мелких камнях/муке купить Мефедрон Кокаин Бошки Марихуану Гашиш Кандалакша купить закладку Ecstasy – UPS

  13. big 5 casino no deposit bonus bet365 mobile casino login casino admiral tivoli lesce casino rewards withdrawal Vodnik po spletni ruleti free slot games download casino joker maribor starburst free spins uk no deposit

  14. Бесперебойная работа любого автомобиля требует надежных комплектующих и первоклассного обслуживания. Специализированный онлайн-гипермаркет https://dieselhard.shop/ предлагает оригинальные автозапчасти и проверенные временем аналоги для европейских иномарок с точным поиском деталей по каталогам и VIN. Опытные мастера также выполняют профессиональный ремонт дизельной топливной аппаратуры.

  15. Looking for slot casino? Visit freeslotsdemo.io to find demo slots top providers and games from Pragmatic Play. Free Slots Demo makes it easy for users to compare slots review RTP volatility and bonus features and pick games by provider theme and format. Learn more on the website.

  16. book of ra deluxe ratio casino bonus app Zavrtite igralni avtomat Book of Ra bet 365 singup bonus

  17. Новоуральск купить Альфа купить Героин Кокаин Экстази Очёр купить закладку Мефедрон миф Купить закладку скорость Змеиногорск купить закладку Мефедрон в мелких камнях/муке Беслан купить VHQ Cocaine 98 Bolivia https://3dhomearchitect.ru Купить закладки гашиш в Новоалександровске Кропоткин купить закладку VHQ Cocaine 988 Ecuador купить Мефедрон Кокаин Бошки Марихуану Гашиш Верхний Тагил купить закладку Cocaine Premium HQ – печать Dolphin

  18. Ищете клиника александра дзидзария? Обратите внимание на biochek.ru — цифровую клинику нового поколения которая заботится о здоровье мужчин и женщин. Вам доступны комплексные программы обследования точные результаты анализов в онлайн-формате и дистанционные консультации профильных специалистов. Запись проводится онлайн а работу осуществляем по Москве и всем регионам России. Подробная информация доступна на сайте.

  19. slot game free delux novoma bonus brez pologa casino queen vegas casino no deposit bonus code play grand casino no deposit bonus Kako igrati spletno ruleto? zodiac casino flash casino games slot free no download casino min deposit 5 euro

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>