@link2xt found this new CRDT called Loro, and they have a convenient Excalidraw example, which I forked and adapted to webxdc real quick.
This is similar to the existing drawing webxdc app, except with that one you can’t collaborate in real time, and that this one has a lot more development effort put into it (i.e. thanks to Excalidraw).
Why it’s a “draft”
- Because the build is too big: 1.36 MB Compressed WASM takes 571 kB, compressed JS – 758 kB, and Delta Chat has a 640 kB limit on
.xdc
size (raise it?? ). This is without static assests. With them it’s ~2.5 MB - I got a permission to fork it from the original devs, but the license is still missing: License? · Issue #1 · loro-dev/loro-excalidraw · GitHub .
- I simply hacked it up real quick, without giving it much thought and properly testing it. Also see TODO comments in the source code.
- That slider at the bottom of the page is not really a thing for end users
Also
I also talked to the Loro devs and asked them if they’d like to incorporate the webxdc changes into their Excalidraw example, and they weren’t really enthusiastic about it. It was before I had written any code.
And if you’re wondering if we can make the app smaller than 640 kB by using a non-WASM CRDT like Yjs, the answer is “probably”. I analyzed the bundle with rollup-plugin-visualizer
and it looked like that excalidraw is included twice. Though see this comment. I’m not sure these assets are actually required, and they’re quite big.
And just yesterday they posted a tldraw example (which is another whiteboard app).