automerge
SyncedStore
Our great sponsors
automerge | SyncedStore | |
---|---|---|
45 | 7 | |
3,110 | 1,618 | |
6.3% | - | |
9.1 | 4.6 | |
3 days ago | about 2 months ago | |
JavaScript | TypeScript | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
automerge
- Automerge CRDT
-
Flutter offline
I'm not aware of any usable CRDT implementations for Dart, my plan is to use the flutter_rust_bridge to make use of automerge v2, which is a full CRDT implementation written in Rust that has the advantage of having a very simple API to work with (basically a key/value store).
- Ask HN: What is new in Algorithms / Data Structures these days?
-
Best local database that works on all platforms including web?
Yes. I asked the devs about ideas for this in this ticket and got an interesting response. It's aimed towards server-side handling, but the same ideas apply to local storage as well.
- Show HN: Pg_CRDT – an experimental CRDT extension for Postgres
-
CRDTs: A Beginner's overview for building a collaborative app
There are a lot of implementations of CRDTs out there. In JavaScript, for instance, we have Y.js (https://github.com/yjs/yjs) and automerge (https://github.com/automerge/automerge). There’s also a Y.js demo (https://demos.yjs.dev/prosemirror/prosemirror.html) that allows you to play around with them and have your own collaborative app running in just a few seconds. All messages are exchange via webRTC and manages the state via CRDTs. This can be a great sandbox to understand how CRDTs work and see.
-
Evan Wallace CRDT Algorithms
Anyone unsure of what a CRDT is, this is the perfect intro: https://www.inkandswitch.com/peritext/
The two most widely used CRDT implementations (combining JSON like general purpose types and rich text editing types) are:
- Automerge https://github.com/automerge/automerge
- Yjs https://github.com/yjs/yjs
-
Should I Move From PHP to Node/Express?
For instance, practicing "local first web" using automerge with all it's Distributed Persistence Primitives on CRDT's and Vector Clocks - i.e. when the Browser View is treated like a Database replica, essentially; or adopting a real data mapper that's giving you an API from your database Schema, using Prisma or Hasura... or even implementing a custom codegenereted one, as a babel plugin, on top of TSED and Micro-ORM.
- Maintaining Referential Integrity During Insertions And Deletions
- Muse 2.0
SyncedStore
-
Local-first software: You own your data, in spite of the cloud (2019)
This article has been quite the inspiration for many projects and progress on this front. I think we're seeing more and more developments around CRDTs and local-first frameworks / applications.
I'm working on a few projects in this area:
- https://www.typecell.org - Notion meets Notebook-style live programming for TypeScript / React
- https://www.blocknotejs.org - a rich text editor built on TipTap / Prosemirror that supports Yjs for local-first collaboration
- https://syncedstore.org - a wrapper around Yjs for easier development
In my experience so far, some things get more complicated when building a local-first application, and some things get a lot easier. What gets easier is that once you've modeled and implemented the data-layer (which does require you to rethink / unlearn a few principles), you don't need to worry about data-fetching, errors etc. as much as in a regular "API-based" app.
Another interesting video I recommend on this topic is about Linear's "Sync Engine" which employs some of the local-first techniques as well: https://www.youtube.com/watch?v=Wo2m3jaJixU
- SyncedStore - build CRDT-powered collaborative Vue apps for the web
- SyncedStore - build CRDT-powered collaborative React apps for the web
- SyncedStore - build multiplayer CRDT-powered collaborative apps for the web
-
Show HN: SyncedStore CRDT – build multiplayer collaborative apps for React / Vue
Hi! Great questions :)
First of all, SyncedStore does not implement any CRDT algorithms. Credits for this go to Yjs [1] (and its author Kevin), which it uses as underlying CRDT.
Yjs and Automerge are (afaik) the two most commonly used CRDT implementations. Both have their pros and cons, but Yjs has focused a lot on performance [2].
Automerge has a bit friendlier "Immer style" [3] API. I'm not too familiar with @localfirst/state, but it seems to add a Redux style API on top of Automerge.
My approach with SyncedStore was really to provide an API on top of Yjs that's as simple as possible to use in React / Vue / Svelte or plain JS app. I.e.: only use a single React Hook to observe changes, and use regular Javascript assigments to update values. The API is inspired mostly by Reactive Programming libraries such as MobX [4] (from the same author as Immer).
Hope you're still following along :) Maybe it helps to compare the TODO-MVC applications, as both SyncedStore (https://github.com/YousefED/SyncedStore/tree/main/examples) and @localfirst/state (https://github.com/local-first-web/state/tree/main/examples/...) have implemented these as examples!
[1]: https://github.com/yjs/yjs
-
Web Applications from the Future: A Database in the Browser
I’m exploring the ideas (an easy to use framework to build local-first [1] apps) in my library Reactive-CRDT (https://github.com/yousefed/reactive-crdt). Feedback welcome!
All credit for the underlying tech to YJS, which has been amazing as mentioned by others in this thread.
[1]: https://www.inkandswitch.com/local-first.html
What are some alternatives?
yjs - Shared data types for building collaborative software
FluidFramework - Library for building distributed, real-time collaborative web applications
crdt-benchmarks - A collection of CRDT benchmarks
RxDB - A fast, local first, reactive Database for JavaScript Applications https://rxdb.info/
y-websocket - Websocket Connector for Yjs
adama-lang - A headless spreadsheet document container service.
Immer - Create the next immutable state by mutating the current one
slate-yjs - Yjs binding for Slate
osmosis-js - JS reference implementation of Osmosis, a JSON data store with peer-to-peer background sync
y-crdt - Rust port of Yjs