Excalidraw: a (draft of a) collaborative drawing app

Download excalidraw.xdc

Source Code

@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?? :pleading_face::point_right::point_left:). 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


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).


A good idea, but I’m not sure if it would take too many emails to sync the apps?

Why? We have the editor app, I think it’s extremely similar in terms of data throughput. Either way, there is a rate limit of 6 messages per minute in Delta Chat. If the limit is hit, the messages are batched together and sent few seconds later.

In my experience, some providers block sending if too many emails are sent in a certain time because their systems interpret this as spam. A large proportion of users will not know how many emails are being sent in the background.

Well, idk. I don’t think it’s something that individual apps are supposed to care about. Perhaps an explicit “send updates” button would do, or the rate limit can be tightened.