When the old and new files being compared are HTML (or markdown), it would be convenient to have the ability to opt into a mode where the output is the original file, with the differences marked with the html <ins> and <del> elements.
Since git-delta already has the ability to detect word-level diff, it seems this could be achievable.
The reason why this would be useful is that when making changes to human readable documents, the source diff isn't always the most user-friendly, and a rendered diff can make life much easier for reviewers.
There already exist a number of standalone htmldiff tools, but:
none of them have the git integration that git-delta has, which makes them much less convenient
many of them tend to mangle the source formatting in various ways, destroying formatting / spacing / line breaking along the way, in a way that a real diff tool wouldn't do.
I guess the biggest challenge is that this would need some degree of syntax awareness, to avoid injecting tags in the middle of html attributes or other invalid locations.
When the old and new files being compared are HTML (or markdown), it would be convenient to have the ability to opt into a mode where the output is the original file, with the differences marked with the html
<ins>
and<del>
elements.For example: Old:
New:
Output:
Since git-delta already has the ability to detect word-level diff, it seems this could be achievable.
The reason why this would be useful is that when making changes to human readable documents, the source diff isn't always the most user-friendly, and a rendered diff can make life much easier for reviewers. There already exist a number of standalone htmldiff tools, but:
I guess the biggest challenge is that this would need some degree of syntax awareness, to avoid injecting tags in the middle of html attributes or other invalid locations.