UNPKG

539 BTypeScriptView Raw
1import semver = require('../index');
2import SemVer = require('../classes/semver');
3
4/**
5 * Compares two versions including build identifiers (the bit after `+` in the semantic version string).
6 *
7 * Sorts in ascending order when passed to `Array.sort()`.
8 *
9 * @return
10 * - `0` if `v1` == `v2`
11 * - `1` if `v1` is greater
12 * - `-1` if `v2` is greater.
13 *
14 * @since 6.1.0
15 */
16declare function compareBuild(
17 a: string | SemVer,
18 b: string | SemVer,
19 optionsOrLoose?: boolean | semver.Options,
20): 1 | 0 | -1;
21export = compareBuild;