3 ms·
Table views are the most striking example. Native table views were designed from the start to lazily load items, and so can trivially support very large lists.
by millstone 6y ago
Table views are the most striking example. Native table views were designed from the start to lazily load items, and so can trivially support very large lists.
The web has no APIs for this. Instead laziness is tacked on through JS, and invariably breaks find, scrolling, etc. Try scrolling to the bottom of your Chrome history: the scrollbar jumps and it's often not clear if/when you reach the bottom.
- anoncareer0212 6y agoUITableView was a solved problem on the web by 2014 at the absolute latest. iOS has scrollbar jumps unless you know the rendered height of every list item and the complete count of list items in advance (which is why Chrome jumps, it doesn't know the entire length of your web history, it's loading it in batches) Funnily enough, _SwiftUI doesn't support lazy table views_. Seriously. It's nuts.
- millstone 6y agoOf course Chrome knows the length of your web history: it's a trivial SQLite call. They just can't display it naturally, because there are no browser-provided APIs for lazy tables. I do not agree that the JS implementations have "solved" lazy tables: they're all invariably broken. For example if you hit cmd-A to Select All, Chrome history just selects what is faulted in. If you scroll down eventually you find unselected items. Safari doesn't have this problem and the main reason is its use of native tables instead of web tables. I agree this is a big hole in SwiftUI as well. A lazy table requires cooperation between the framework and the app, which is an awkward fit for declarative UI frameworks like SwiftUI and the web.
- nmjenkins 6y agoWhile it's not built in, this is totally solvable in a performant way on the web. Fastmail's web UI lazy loads in mailbox lists of messages (which for some users can be 1,000,000+ items long). The scrollbar is correct and you can jump to an arbitrary point. You can select all. We've had this for, I dunno, 7+ years now?
- millstone 6y agoFastmail is indeed a radical outlier on this front, by far the best of the bunch. Its lazy tables are still broken (Find and Print for example) but they get scrolling right, and that is significant. It's not at all representative of the experience of using Gmail, Ymail, Hotmail. The web requires heroics to get quality.