Closed deinspanjer closed 11 years ago
Agreed. I'll put it out of the README though, but definitely some docs are needed.
That would be interesting for me too... I'm trying to see if there is an easy way to detect conflicts between multiple patches.
Is there any particular reason this library does not use the "JSON Patch" standard (http://tools.ietf.org/html/rfc6902)? It might make the patches more compatible with other libraries.
@johanfforsberg there's no particular reason, I wasn't aware of the existence of that format when I created this lib (based on that page it seems that's from april 2013, so it didn't exist when I created jsondiffpatch), but it's a great idea.
my main goals when designing the jsondiffpatch format were:
At a quick glance, I'm not sure the 2nd goal was pursued with JSON Patch, but it's just my first impression.
Nevertheless, standards are always welcome. So the main blocks I see are:
You are right, JSON Patch is very new as a standard. I was mostly curious if you had any technical reasons to not go with it, i.e. some particular shortcomings. I personally find JSON Patches readable, but it does have quite some overhead of the changes themselves are small.
I've found several JSON Patch implementations, but none that was as well suited to my needs as JsonDiffPatch, and for my use it does not matter very much what internal format is used.
(I guess this discussion has left the topic of the original issue, though. Perhaps best to create a new issue about JSON Patch?)
yes that sounds good, thanks!
Please consider taking the text in this other issue's comment and putting it in the readme. It is exactly what I was looking for.
https://github.com/benjamine/JsonDiffPatch/issues/12#issuecomment-14426436