Hi I am new to Yjs and collaborative editing. For my thesis I am looking into a real implementation comparison between OT and CRDT performance for real time collaboration. I am working with Overleaf as the text editor. Overleaf currently uses ShareJS for its OT implementation. I want to use Yjs to rewrite the collaboration code in Overleaf to use Yjs’s CRDT implementation. Is this possible? And if so, does anyone have any tips for getting started? Thanks!
Hi @lacraft, what a fantastic idea!
I think the main challenge is to rip-out OT and integrate Yjs. That means you need to modify a lot of client-code and you need to modify a lot of server code. I feel that this could be a very ambitious project.
This is basically what I do to monetize Yjs. I work as a contractor to integrate Yjs into existing products. Most teams find it challenging to find the right approach to make an application collaborative. It requires you to understand the codebase and to integrate Yjs into the existing communication protocol.
You could ask the authors to give you a tour and ask them what they think about this. The main-advantage of Yjs over ShareJS is scalability, offline editing, and decentralization. None of this is interesting to Overleaf. Since Latex documents need to be stored on a central server for compilation, I’m not sure if it makes sense for them (or for you) to go through this effort. They have a good thing going and there is no significant advantage in switching to Yjs. However, if you make it happen, I’ll find another job for you
Rather, you could maybe try to make another single-user application collaborative. From the top-of my head: drawio and diagrams.net would be nice projects to make collaborative.