6 ms·
This looks great, nice work. Do people using this sort of thing (or the YouTube style top of the page loading bar) actually get back real % completed values fr
by lostsock 13y ago
This looks great, nice work.
Do people using this sort of thing (or the YouTube style top of the page loading bar) actually get back real % completed values from the server or do they just use it to show that _something_ is happening?
- refrigerator 13y agoI think the vast majority of sites just make the progress bar move in a way such that it appears to be loading quickly/making progress, but when the server is finally ready the bar just jumps to the end.
- Gigablah 13y agoInternet Explorer on Windows Mobile does this too. If your connection drops out, the progress bar continues to move towards 90%, then gets stuck there forever. It's maddening.
- ygra 13y agoThat being said, giving a good estimation of page load time is downright impossible. You don't know in advance how many resources you need to load, you don't know in advance how large they'll be, or how long the DNS reply will take ... If you don't want the scrollbar to move backwards, you can just give a rough approximation of progress, if any. And if you just wait until you certainly know how long it's going to be you're probably almost finished anyway. I guess there's a reason web browsers nowadays just use a little spinner that says »I'm doing ... uhm ... something!« instead of them pretending »I'm 46.5 % done«.
- oneeyedpigeon 13y agoYou can't do this very accurately, sure, but you can add some meaning - e.g. report back when each of a number of known steps is completed. That gives a vague idea of whether we're talking seconds or minutes. I might be able to do something else once I know a specific step is complete.
- baddox 13y agoThe obvious exception would be file uploading, which can and should have a true progress indication.
- mmanfrin 13y agoI built an importer script once -- the importing itself was handled in a worker, so when the file was first submitted, the importing would be done on a separate thread in a Transaction -- pretty much making it impossible to actually track progress. I set it so that it would 'tick' up a couple % every Math.rand(0..2) seconds; but also poll for the statuses I did know about (accepted, queued, started, finished). It honestly made for a very comfortable UX -- customers did not know it was not actually representative of the true status, but they were nevertheless okay with waiting the 30~ seconds it took.