tldraw
@tldraw
Followers
71K
Following
7K
Media
2K
Statuses
5K
infinite canvas | https://t.co/oXL4NAc6P8 | https://t.co/dO6WPp6YOI | https://t.co/beo7WsKiVe | /tiː ɛl drɔː/
London
Joined February 2021
Probably my favorite feature in @tldraw Past in a link and it creates these nice graphics from it 🤩
1
5
45
We're hoping to find more places to ship less code and sync fewer bytes. If you're into this kind of thing, you can read through the pull request here:
github.com
This PR reduces the storage size of draw and highlight shapes by encoding point data as base64 strings using Float16 representation instead of JSON arrays of VecModel objects. Each point (x, y, z) ...
0
0
0
Resizing draw shapes should now be faster too. Previously, we would rescale points during resize to fix the shape's new bounding box. We now store the differences in x/y scale separately and multiply at render time. Less work to do and less to sync.
1
0
0
It might also help with performance. Although the points are stored in a compressed format, we don't need to decode the whole array in order to access points. We are able to selectively decode any point within the compressed array because the bits in the array are regular.
1
0
0
This is meant to address a common issue we've seen where files containing many hand-drawn shapes would become unexpectedly large, leading to slower loading times and synchronization. Those files should be up to 80% smaller now.
1
0
0
In the next version of tldraw, we're introducing a compressed format for storing points for freehand shapes. Each point (x, y, z) is now encoded as 6 bytes (3 Float16 values) = 8 base64 characters, compared to approximately 40+ bytes per point in the previous JSON format. This
2
1
29
Finally I've been able to set up a satisfactory animation system in @tldraw and can continue adding features. Now playing with ideas for path animations
0
1
86
Need a deep Safari bug to impress your lover? Try this: - google for a "cursed text generator" - create some cursed text with lots of diacritics - open tldraw dot com in Safari - paste cursed text - move it around
4
4
66
This week we landed a change to our collaboration backend, tldraw sync, that makes the @Cloudflare durable object's "working document" live in the new SQLite storage rather than in memory.
2
8
59
the picture on the left was drawn by a tldraw fairy and other a book cover designer. are we seeing a convergence here?
0
1
5
In the next version of tldraw, we fix a very entertaining bug that would effect flipping rotated shapes that include freehand shapes.
0
3
31
Buy now at https://t.co/A4EuyTHCbl. $25. December only. Unshipping in January. Experience the future, today, and for the next 20 days.
0
0
1
The new strategy is live now on tldraw .com and you can check out the source as always on https://t.co/T1VBkMw658.
github.com
very good whiteboard infinite canvas SDK. Contribute to tldraw/tldraw development by creating an account on GitHub.
0
0
1
Most importantly, however, we now have a guarantee that the server knows whether its persistence strategy is working. If something fails or fails to work as expected, we can recognize the issue immediately (synchronously!) and alert any connected clients.
1
0
0
For example, we could have the client fetch a recent snapshot of the document state from a CDN. Then when it connects to the durable object via WebSocket it only needs to "catch up" by asking for the updates since the snapshot was written.
1
0
0
There are however still times when the server needs to load the whole document into memory. Currently, when a new user joins, the server will need to load everything in order to send the whole document to the new client. There are ways around this though...
1
0
0
As the server runs, it should also keep memory usage much lower as the server is using the database as an cache (or at least a very fast off-heap data store).
1
0
0
We expect it to improve the server's startup time as the data it needs is available synchronously once the durable object is created, skipping the work of fetching and deserializing the initial snapshot from R2.
1
0
0