bem / html-differ

Сompares two HTML
http://bem.info/tools/testing/html-differ/
MIT License
211 stars 44 forks source link

Options to add <ins> or <del> tag with custom class in result? #170

Open vickyRathee opened 3 years ago

vickyRathee commented 3 years ago

Anyway to print the result with <ins> and <del> tag?

var first = "<p>This is a paragraph</p>"
var second= "<p>This is a changed paragraph</p>"

var diff = htmlDiffer.diffHtml(first , second);

// Should result in
<p>This is a <ins>changed</ins> paragraph</p>
Keanottesen commented 3 years ago

Have you implemented this yourself? I am struggling with it as it fails to give me satisfying results when deleted elements spans over multiple HTML elements.

vickyRathee commented 3 years ago

@Keanottesen No, we have this project on hold.