Function: compareVersions()
compareVersions(
a,b):number
Defined in: src/lib/schemas/index.ts:56
Compare two major.minor.patch versions: negative when a is older, positive when newer, 0 when the same. Versions
that can't be read sort first.
Parameters
a
string
b
string
Returns
number
Example
compareVersions("1.2.0", "1.10.0"); // negative