Ace-editor example for v13?

Made an issue about this yesterday, but perhaps it’s better to bring up for discussion here? In the FOSDEM talk it was mentioned that there’s current support for ace-editor, but I couldn’t find an example in the current version… only an old reference on y-js.org – but I’m guessing the whole API etc has changed quite a bit since then.

Curious to test Yjs as the collab backend of COCODING on P5LIVE which is currently using the CRDT implementation from peeredit – of which I could imagine both peeredit’s rga.js and Yjs’ CRDT algorithm are based on the HAL paper? Was just listening to the peer-to-peer podcast and dug the idea of hotswapping between webRTC + websockets. Websockets sounds like the more stable system especially if a tool is used in a classrooom setting with 25 peers… but if 1:1 or so and used for live-coding-music-collaboration, sounds like webRTC would produce the least latency = Yjs can do both?? Also interested in being able to completely replace the shared contents/editor with new text and paste large chunks of code between peers. The demo’s on Yjs.dev are really impressive for pasting/syncing chunks of text… curious if one would have the same results using ace-editor??

ps. I’m tracking cursor positions in ace-editor, so perhaps I can help somehow to give that binding a √

Hey @ffd8, sorry for the late answer.

Unfortunately, an ace binding still doesn’t exist for Yjs v13.

The editor bindings for text editors are actually pretty straight forward to implement. Have a look at https://github.com/yjs/y-codemirror. The hard part is tracking and rendering cursor positions.

There is a bit of documentation on the Yjs approach in the readme.

Websockets sounds like the more stable system especially if a tool is used in a classrooom setting with 25 peers… but if 1:1 or so and used for live-coding-music-collaboration, sounds like webRTC would produce the least latency = Yjs can do both??

Sure, you can use any provider in any combination (even several providers at the same time).