-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Are there any diffing mechanisms for mobiledoc ? #653
Comments
I'm interested in something like this too so that we could handle two users editing the same document a little more gracefully server-side. In my initial research I looked at JSON diffing libraries such as https://github.com/andreyvit/json-diff but haven't tried it against mobiledoc yet. |
Seems like it'd have to be pretty specific implementation using the json-diff (or the like) coupled to the mobiledoc structure/format. |
Creating 2 versions of text:Version 1:
Renders:
Version 2:
Renders:
Exploring the diff:Using https://benjamine.github.io/jsondiffpatch/demo/index.html Paste the 2 versions into the left / right inputs Perhaps someone versed with mobiledoc could pitch in and help explore if this would be easy to render as a visual diff of the two versions. |
at bustle we use a fork of a diff/patch for storage of revisions https://github.com/bustle/yadiffjson/ And then render to html and use https://www.npmjs.com/package/htmldiff which is super old but works (haven't touched this part of our code in a long while). |
Looking at ways to provide quality diffing on rich user input, and there doesn't seem to be a whole lot of options.
The text was updated successfully, but these errors were encountered: