ueberdosis/hocuspocus

What's the best way to edit the document server-side?

Closed this issue · 3 comments

linspw commented

The problem I am facing
I'm needing to handle document-side changes when it's live on the hocuspocus server.
However, when changed by the server, it does not trigger the save document events.

The solution I would like
I don't know the best way, but there could be some way to make clearer edits to the ydoc on the server side so that it triggers the main events.

Alternatives I have considered
I'm getting the document directly from the "documents" property of the server
image

hey @linspw, we have a DirectConnection in Hocuspocus (I'm working on the documentation for this), but it can already be used: #610

Let me know if that helps 🙏

linspw commented

Thank you very much for this here too @janthurau , it will help a lot!

linspw commented

I still haven't had time to go back to that point where I was working, but as soon as I get back to working on it, I'll send feedback here.