Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

// request.cf · coarse context

A page that knows where it met you.

Only coarse request metadata is shown. This demo does not display or persist visitor IP addresses.

Country
US
Cloudflare location
CMH
Connection
HTTP/2
Language
Not provided

Ray ID: a21e1c649fcddafe

Jump to content

Module:Diff/doc

From Wikipedia, the free encyclopedia
Diff
DescriptionProvides functions for diffing text.
Author(s)
  • Yuri Takhteyev (yuri@freewisdom.org)
  • Hisham Muhammad
  • User:Ebrahim
Status
Release
Testcase Status
Unknown
UpdatedFebruary 14, 2026 (5 months ago)
LicenseMIT/X

Provides functions for diffing text.


Usage

Ciaran Hope (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.

Difference in words

{{TextDiff|[[Ciaran Hope]] (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.|[[Ciaran Hope]] (was given birth to on 20 August last year) is an Irish composter of orchestral, oral, and film music dance moves.}}

Result:

[[Ciaran Hope]] (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.
+
[[Ciaran Hope]] (was given birth to on 20 August last year) is an Irish composter of orchestral, oral, and film music dance moves.
[[Ciaran Hope]] (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.
+
[[Ciaran Hope]] (was given birth to on 20 August last year) is an Irish composter of orchestral, oral, and film music dance moves.

Difference in characters

{{StringDiff|[[Ciaran Hope]] (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.|[[Ciaran Hope]] (was given birth to on 20 August last year) is an Irish composter of orchestral, oral, and film music dance moves.}}

Result:

[[Ciaran Hope]] (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.
+
[[Ciaran Hope]] (was given birth to on 20 August last year) is an Irish composter of orchestral, oral, and film music dance moves.
[[Ciaran Hope]] (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.
+
[[Ciaran Hope]] (was given birth to on 20 August last year) is an Irish composter of orchestral, oral, and film music dance moves.

Example with invoke

{{#invoke:Diff|main|[[Ciaran Hope]] (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.|[[Ciaran Hope]] (was given birth to on 20 August last year) is an Irish composter of orchestral, oral, and film music dance moves.}}

Result:

[[Ciaran Hope]] (born 4 August 1974) is an Irish composer of orchestral, choral, and film music.
+
[[Ciaran Hope]] (was given birth to on 20 August last year) is an Irish composter of orchestral, oral, and film music dance moves.

Documentation

Package items

diff.diff( old, new, separator ) (function)
Returns a diff of two strings as a list of pairs, where the first value represents a token and the second the token's status ("same", "in", "out").
Parameters:
old The "old" text string
new The "new" text string
separator [optional] the separator pattern (defaults to any whitespace). (optional)
Returns: A list of annotated tokens.
diff.wikiDiff( old, new, separator ) (function)
Wiki diff style, currently just for a line
Parameters:
old The "old" text string
new The "new" text string
separator [optional] the separator pattern (defaults to any whitespace). (optional)
Returns: HTML formatted diff
diff.main( frame ) (function)
Main entry point.
Parameter: frame Calling frame. (table)
Returns: wikitext output

Other items


Documentation above is auto generated