Skip to content

Latest commit

 

History

History
32 lines (19 loc) · 633 Bytes

File metadata and controls

32 lines (19 loc) · 633 Bytes

html-diff-js

Diff tool for html documents, disregarding markup

Dependencies

jQuery: converting text into plain text including HTML Entities

Diff Match Path: http://code.google.com/p/google-diff-match-patch/

Underscore.js: Utility functions

Usage

to produce a html diff marking insertions and deletions using the <ins> and <del> tags:

HtmlDiff.formatTextDiff(originalText, finalText)

see the code of this method to get the individual steps if you want the diff in array form.

License

This library is released under the MIT license