10 ms·
Another 10k Apart: Create a Website in 10 KB, Win Prizes
- 3princip 10y ago>Build a compelling web experience that can be delivered in 10KB and works without JavaScript. It's difficult to imagine what such an experience would contain, CSS animation trickery? I'm very pro minimal UI code, my last hobby project didn't include any framework libraries and the front-end came in at 23kb including images, CSS, HTML and JS. But without a back-end, and without JS (no SPAs), is this just a contest to build the best looking static page?
- ewindisch 10y agoReading through, it seems that JS is allowed, but the page needs to be functional without it. Ideally, the page would work with Lynx.
- callumlocke 10y agoLooks like the 10KB can include a back end: https://a-k-apart.com/faq#stack https://a-k-apart.com/faq#stack
- aarongustafson 10y agoYou can use a back-end in Python, Node, PHP, or .NET Core. The size of your back-end doesn’t factor in, just the markup, CSS & JS you deliver.
- nathancahill 10y agoFrom the 5k challenge in 2000: "Indeed, the winning site offered a witty yet powerful critique of the current state of the web via a fully functional e-commerce shopping cart. In less than 5K. Bastards." The winning site: http://web.archive.org/web/20000510060852/http://www.sylloge.com/5k/entries/182/index.html http://web.archive.org/web/20000510060852/http://www.sylloge...
- astazangasta 10y agoWhere "fully functional" means "just a dummy, can't actually manage payment or shipping".
- latch 10y agoI know a simple blog isn't the type of site this contest has in mind, but a couple years back I tried to shrink my blog's homepage. I got some good feedback and was happy with the result. Since I go long stretches of time without doing frontend, I felt it was a worthwhile exercise. This is what I learned from the experience: http://openmymind.net/Minimalist-Markup/ http://openmymind.net/Minimalist-Markup/
- dogma1138 10y agoIs the 10kb limit per page? Per site(including backend)? Per content served to the user on a single page load?
- maxmcd 10y agohttps://a-k-apart.com/faq#size https://a-k-apart.com/faq#size
- nekinie 10y agoNo Golang support :(
- deleted 10y ago[deleted]
- archgrove 10y agoWoah now, everyone knows making a site with less than 10,000 dependencies isn't possible these days. Wait, we're talking about bytes?
- jonatron 10y agoUsing tabs instead of spaces should help
- aarongustafson 10y ago:-) Although minification & GZip should even those out.
- thecosas 10y agoThis argument makes perfect sense to half of the people reading here :ob
- meanJim 10y agoI got really excited until I realized I couldn't use JavaScript. Over the last year I got super passionate about making the smallest JavaScript bundle size possible with RiotJS or Preact. I guess they really mean the old school 'website' (like the html 1.0 strict days), so maybe a html document with everything inline and no special fonts.
- fomq 10y agoYou can use JavaScript, just not JavaScript libraries.
- clarkmoody 10y agoNot true. JS libraries simply count against your 10kB. In the past, they may have been "free resources"
- fomq 10y agoSo what does this mean?: "In order to encourage folks to use native JavaScript functionality and keep their project as slim as possible, this year we’ve chosen to remove JavaScript libraries from the “free resource” camp."
- detaro 10y agoYou could previously include JS libraries and they didn't count against the 10k limit. now they do. EDIT: Somehow, since lazy-loading not strictly required stuff apparently doesn't? (https://a-k-apart.com/faq#size https://a-k-apart.com/faq#size)
- aarongustafson 10y agoYou can lazy load libraries for sure. I would still keep those to a minimum, including only what you need. For instance, don’t load all of jQuery if you only need one feature. And use native JavaScript code when you can get away with it—dataset instead of data(), querySelectorAll() instead of $(), etc.
- reitoei 10y agoCue massive traffic spikes on http://microjs.com/ http://microjs.com/
- thecosas 10y agoNo Javascript :-(
- aarongustafson 10y agoYou can use JavaScript, but it needs to be an enhancement, not necessary for the user to do what they need to do.
- eddieh 10y agoCool, but the contest page (https://a-k-apart.com https://a-k-apart.com) is 204.5 K. Disappointed.
- aarongustafson 10y agoDisable JS and view on a small screen :-) It progressively enhances to that size. I’ll be writing about the process and design in forthcoming posts. Smallest view (240px wide) with no JS renders in 6.9kB (DOMContentLoaded hit at 94ms, Load at 119ms). Also in play: client-side caching with ServiceWorker and some localStorage goodies to speed things up on modern browsers.
- detaro 10y agoHonestly, >10k google analytics doesn't sound like "progressive enhancement" from a user perspective, but I get why it's included. How would that be rated in the actual challenge? (Maybe do and publish a mock "grading" of the announcement page as an example, to make clearer how the rules work?)
- aarongustafson 10y agoI plan to write up how the site was built and give some hints as to how you can use lazy loading, etc. to your advantage.
- aarongustafson 10y agoOut of curiosity, which browser are you in? I get 87.9K for the homepage, including all dependencies, lazy loaded JS, the SVG hero, etc. Are you getting WebP images or PNG?
- eddieh 10y agoLatest stable Safari on desktop (9.1.2). Getting jpegs actually.