Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/hex/src/lib/mod.ts>stdx.semver.cmp

An ecosystem delivering practices, philosophy and portability. Powered By Deno and JavaScript.
Latest
function stdx.semver.cmp
import { stdx } from "https://deno.land/x/hex@0.6.5/src/lib/mod.ts";
const { cmp } = stdx.semver;

Pass in a comparison string, and it'll call the corresponding comparison function. "===" and "!==" do simple string comparison, but are included for completeness. Throws if an invalid comparison string is provided.

Parameters

v1: string | SemVer
operator: Operator
v2: string | SemVer
optional
options: Options

Returns

boolean