Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

and has a page load of 125kb (including my picture)

Imagine what you could get it down to if you just wrote CSS instead of using a framework.



11.5KB of CSS, looks like you could probably take it to under 1KB. But the biggest weight is the 93KB 460×460 avatar image which is used in a 100×100 circle. That can be reduced to an decent JPEG of about 10KB without even shrinking it to 100×100. At 100×100 (low-DPI displays), it’s under 5KB. I’d probably go for a single 200×200 image weighing about 8KB.

If you wanted to make that page really fast, you’d inline all the CSS and the avatar image, and get it under 14KB so that the entire HTTP message could be transmitted in one TCP packet.


What network are you on that gives you 14kb packets from the internet?

My loopback has MTU of 16kb, everything else is 1500 or less


Oops, off by an order of magnitude, sorry. It’s been a while since I’ve seriously optimised anything in this sort of way (purely for fun).


Well speed was not the main goal of my site. I just wanted to build something quick. I sometimes use the avatar on my page to upload it somewhere else and a decent resolution is good for that.


The framework he uses is actually 996 bytes minzipped :D (disclaimer : I'm the creator of https://concrete.style)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: