Actionscript Diff is a library that provides an implementation of the Myer’s diff algorithm. This is a port from the Java implementation of the algorithm as is provided by the google-diff-match-patch project written by Neil Fraser of Google.

Some features:

  • Simple API to interact with the diff algorithm
  • Returns diff boundaries of letters which have changed, and letters which haven’t
  • Pure AS3 implementation (no Flex SDK required)
  • Documentation!

Sample

var diffs:Array = new Diff().diff(beforeText.text, afterText.text);
Misc . URL.