Skip to content
MapSVG 8/Documentation

compareVersions()

function compareVersions(v1, v2): -1 | 0 | 1;

Compares two version strings (e.g. “1.2.3”).

ParameterTypeDescription
v1any
v2any

-1 | 0 | 1

1 if v1 > v2, -1 if v1 < v2, 0 if equal