by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Bobby Z.
    @619
    What I'm trying to do is allow collab on any website by using mutation summary to observe dom changes, translating to OT, and sending it to other users
    How should I do this using gulf? I've tried using ContenteditableDocument as well as the basic example
    Marcel Klehr
    @marcelklehr
    You're probably doing it correctly and the library is broken
    Bobby Z.
    @619
    :(
    Marcel Klehr
    @marcelklehr
    to exports
    Bobby Z.
    @619
    I will try and get back to you
    Marcel Klehr
    @marcelklehr
    :ok_hand:
    Marcel Klehr
    @marcelklehr
    here you go, I've published a new version, as it might not be as easy as advertised for you to make that change
    @619 ^^
    Bobby Z.
    @619
    sorry, still doing it and fixing bugs
    Marcel Klehr
    @marcelklehr
    @619 I've published a new version of gulf-editor-contenteditable to npm :)
    Bobby Z.
    @619
    It works now
    But unfortunately what I want to do does not work
    Marcel Klehr
    @marcelklehr
    yay :)
    document.body
    Bobby Z.
    @619
    Screen Shot 2020-04-15 at 6.14.44 PM.png
    tried both document body and a p tag
    editing the text does not propagate the changes to other tabs
    Marcel Klehr
    @marcelklehr
    you're using both gulf-contenteditable and gulf-editor-contenteditable
    Bobby Z.
    @619
    Screen Shot 2020-04-15 at 6.15.53 PM.png
    Marcel Klehr
    @marcelklehr
    gulf-contenteditable is legacy
    Bobby Z.
    @619
    Yea I think also adding another div into the master document on server side is bad
    Marcel Klehr
    @marcelklehr
    don't use it
    Bobby Z.
    @619
    ok
    What should I use instead of a newly initialized div on the server side?
    for gulf.document.create
    Marcel Klehr
    @marcelklehr
    I don't know
    You want to sync the body then use something like <body></body>
    Bobby Z.
    @619
    Okay
    Marcel Klehr
    @marcelklehr
    it will override any existing contents of document.body, though
    so, eventually in your app, you might want to send those initial contents to the server prior to setting up the syncing
    Bobby Z.
    @619
    aw, thats not right
    Ok I see
    Bobby Z.
    @619
    No, a clone of the html does not work :/
    oh wait, nevermind
    it does work!
    🥳
    Thanks a lot my dude
    Bobby Z.
    @619
    Ah, I spoke too soon... :(
    Bobby Z.
    @619
    Screen Shot 2020-04-15 at 7.30.38 PM.png
    passing document.body into contenteditabledocument
    Bobby Z.
    @619
    I cannot get this to work.
    Marcel Klehr
    @marcelklehr
    heh, you found another bug.
    Seems like I didn't test that component after the v5 rewrite
    @619 Should be fixed on npm now