Skip to content
This repository has been archived by the owner on May 24, 2024. It is now read-only.
/ semver-compare Public archive

↔️Compare semver according to Semantic Versioning with a high performance semver parser.

License

Notifications You must be signed in to change notification settings

vivaxy/semver-compare

Repository files navigation

@vivaxy/semver-compare

Build Status NPM Version NPM Downloads MIT License Standard Version Codecov

Install

yarn add @vivaxy/semver-compare or npm i @vivaxy/semver-compare

Usage

import semverCompare from '@vivaxy/semver-compare';

console.log(semverCompare('1.0.0', '1.0.1')); // => -1

Benchmark

hobbyquaker/semantic-compare x 69,697 ops/sec ±5.74% (83 runs sampled)

asamuzaK/semverParser x 136,009 ops/sec ±0.81% (90 runs sampled)

npm/node-semver x 136,487 ops/sec ±1.27% (88 runs sampled)

omichelsen/compare-versions x 140,054 ops/sec ±2.73% (76 runs sampled)

vivaxy/semver-compare x 197,073 ops/sec ±3.13% (85 runs sampled)

Fastest is vivaxy/semver-compare

Related Projects

Project created by create-n.