问题描述
是否有任何人都知道的JQuery可视化diff插件.您会在GitHub,BitBucket或任何标准源代码控制网站上看到类似的内容吗?
is there a JQuery visual diff plugin that anybody knows about. Something like you would see on GitHub, BitBucket, or any standard source control site?
我发现了这个 https://github.com/cemerick/jsdifflib ,它看起来还不错,但想知道是否还有更多类似的东西.
I have found this https://github.com/cemerick/jsdifflib and it looks pretty good, but wonder if there are more out there like it.
谢谢.
推荐答案
我认为您应该考虑做一个自制的插件来做可视化的事情.
I think you should consider doing a home made plugin, to do the Visual thing.
有一个jquery插件,可让您进行$ diff比较,例如这 :
There is a jquery plugin which allow you to do $diff comparison like this one :
通过此操作,您可以获得可用的元素集合:
By using this you get a usable collection of elements:
$.diff(obj1, obj2) return {mod: ..., add: ..., del: ...}
您可以使用jsfiddle为您自己的插件(http://jsfiddle.net/)制作原型
You could use jsfiddle to prototype your own plugin (http://jsfiddle.net/)
这篇关于jQuery Visual Diff插件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!