Re:Show HN: Nash, I made a standalone note with single HTML ...
by Imustaskforhelp on Sunday March 16, 2025 @11:58AM
(#43380030)
This is a truly a great insight from how simple things can create industry giants like google docs.
I believe that a lot of problems can be converted into synchronization problems in browsers.
Are there any general synchronization libraries / applications that you suggest within browser / outside browser?
Thanks in advance.
Re:Show HN: Nash, I made a standalone note with single HTML ...
by pkage on Sunday March 16, 2025 @01:59PM
(#43380864)
Not OP, but common solutions in this space represent the state as conflict-free replicated data types (CRDTs). Some popular browser-based libraries for that are Y.js[0] and Automerge[1].
[0]: https://yjs.dev/ [1]: https://automerge.org/
Re:Show HN: Nash, I made a standalone note with single HTML ...
by nextaccountic on Monday March 17, 2025 @05:45AM
(#43386672)
By the way, for those wanting to do this but in Rust, there is https://crates.io/crates/yrs and https://crates.io/crates/automerge
Re:Show HN: Nash, I made a standalone note with single HTML ...
by babymode on Monday March 17, 2025 @06:38AM
(#43386965)
And Loro [1], relatively new player which recently hit 1.0, with solid performance and some features the others don’t have
[1]: https://loro.dev/
Re:Show HN: Nash, I made a standalone note with single HTML ...
by nextaccountic on Monday March 17, 2025 @06:54AM
(#43387086)
Amazing, thanks for the link
What features does Loro have that others lack?
Re:Show HN: Nash, I made a standalone note with single HTML ...
by nashashmi on Sunday March 16, 2025 @08:19PM
(#43383918)
I thought it was a dynamic text box souped up with all sorts of tricks and semantics to make it appear like a rich text editor
Re:Show HN: Nash, I made a standalone note with single HTML ...
by snewman on Monday March 17, 2025 @02:26AM
(#43385661)
I'm not sure exactly what you mean by "dynamic text box" but it was just a contenteditable div. There have been at least two complete rewrites since I was involved, nowadays I believe it's a canvas with all of the editing, formatting, layout, and rendering done "by hand" in JavaScript.
Re:Show HN: Nash, I made a standalone note with single HTML ...
by nashashmi on Monday March 17, 2025 @11:19AM
(#43389503)
The kind of text box used in php forums ... called text area I think, and this would be hidden every time the focus went away and an HTML based layout presented in its place. This seemed to be clunky but I thought that was what made writely possible. ContentEditable is such a breath of fresh air had I ever known about it. I wonder if IE6 supported that.
The other 90% was all the backend code we had to write to properly synchronize edits across different browsers, each with their own bizarre suite of bugs in their contenteditable implementations :-)