文件名称:unidiff:统一差异格式的javascript diff
文件大小:20KB
文件格式:ZIP
更新时间:2024-05-26 06:08:58
JavaScript
unidiff unidiff为jsdiff添加了创建的 以下代码段: var unidiff = require('unidiff') var diff = unidiff.diffLines( 'a quick\nbrown\nfox\njumped\nover\nthe\nlazy\ndog\n', 'a quick\nbrown\ncat\njumped\nat\nthe\nnot-so-lazy\nfox\n' ) console.log(unidiff.formatLines(diff), {context: 2}) 产生以下输出: --- a +++ b @@ -1,8 +1,8 @@ a quick brown -fox +cat jumped -over +at the -lazy -dog +not-so-lazy +fox 使用diffA
【文件预览】:
unidiff-master
----.gitignore(102B)
----rollup.js(548B)
----package.json(873B)
----hunk.js(9KB)
----package-lock.json(40KB)
----LICENSE(772B)
----unidiff.js(3KB)
----readme.md(2KB)
----test()
--------test_unidiff.js(6KB)
--------example.js(244B)
--------test_hunk.js(2KB)