Hacker News new | past | comments | ask | show | jobs | submit login

i'm wondering how much kb it loads before ready to search?

update: 144KB for JSON file

a little bit worrying, given their scale and potential bandwidth requirements




Yeah I would think this file size will increase well over time. Maybe a part 2 of the article can go over how updates to the file are made when new content is published and possible scaling solutions.


For content like this, it's much easier to download the entire search-index.json and run the auto-complete against that.

Rather that than hitting a search endpoint (after typing a certain amount of characters).


Sadly in 2021 adding 140KB to a page isn't a big deal (given how heavy the rest of the page probably is) - but it really should be.

A large chunk of the world's population still pays a locally-expensive rate for mobile bandwidth, and we're increasingly leaving them behind - or worse, pushing them into zero-rating internet plans which mean they can only use Facebook and WhatsApp while avoiding the rest of the web: https://en.wikipedia.org/wiki/Zero-rating


It's only added if the user shows an intent to search. And if you want to search, 144kb is a decent price to pay for instant search once it's downloaded


Oh I'd missed that - yeah loading it on-demand the first time they attempt to search is a much better strategy.




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

Search: