Hacker News new | ask | show | jobs
by remkop22 986 days ago
You could make the exact same argument for something like git. Yet everybody would be totally fine if their remote/origin is down for a couple of hours. Offline support is about bridging smaller periods of being unconnected while still enabling the user to be somewhat productive.
1 comments

Git has much more explicit conflict resolution though, which covers a lot of the risks involved
And CRDTs already solve this, which is what I assume notion uses.
No, it was not using CRDTs when I last checked (more than a year ago). If you're designing for online-only, you can cheat a little and be "good enough".

Setting properties is a last write (to the server) wins (set path foo on block XXX to Y). So text changes overwrite the entire block. The contents of a page are a list of block ids. The operation is "insert id XXX after YYY", and if YYY is not found (deleted/moved), it's placed at the end of the list.

But the biggest impediments to offline for Notion (again when I last checked) were that it doesn't have a full copy of the data and some of the operations are executed server-side (autocomplete dropdowns, search, and some bulk operations). I was hoping they would deal with the former, because it'd make it easier to backup and process my data. But I ended up moving on.

I think they've dealt with some of the search operations, but are still not syncing all of the blocks.

Interesting, that actually surprises me. Thanks for clarifying!
I don't think there's truly any technical solution to "two users edited the same piece of text" tbh. You can try to be smart about it in various ways, but at the end of the day you're still going to hit situations where it's really not clear what the users' intent would be to handle two mutually-unaware edits on the same words
CRDTs handle exactly that. There are times where things aren't exactly as the user intends but at least there's a way to determine a resolution.
I meant in terms of achieving the intended outcome for the end-users. Is it actually desirable to ensure there's a resolution when really they need to decide?