Skip to content

Comment on Diff Algorithmsparent

Comments

The first is:

    One paragraph.

    Followed by another.
The second is two bold letters, one after another in a single word.

However if the html is "an application" more than it is "a document" - a b-tag with two letters, might be meaningfully different from two b-tags in sequence (for example with css:)

   b { display: block }
So, I'd say as a fragment two bold tags might be mergable - but not in the general case?

Ed: ie if diffing input from a html input field (rich editor) merging bold tags would probably be what you want - when the first edit bolds first letter, and second edit bolds second letter.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.