Skip to content

CodeMirrorModule.cmpPos method

CodeMirrorModule › cmpPos

Unofficial

Compares two positions.

Signature:

cmpPos(a: Position, b: Position): number

Parameters:

Parameter Type Description
a Position The first position.
b Position The second position.

Returns: numberA negative number if a is before b, positive if after, zero if equal.