HTML Diff Script Service

Last modified by Vincent Massol on 2021/04/06

A new script service is available to compute the visual changes between two HTML fragments:

<div class="html-diff">
  #set ($htmlDiff = $services.diff.html.unified($previousHTML, $nextHTML))
  #if ($htmlDiff == '')
    No changes.
  #elseif ("$!htmlDiff" == '')
    Failed to compute the changes.
  #else
    $htmlDiff
  #end
</div>

Checkout the Diff Module's documentation for more information.

Get Connected