Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

std/semver/mod.ts>major

Deno standard library
Go to Latest
The Standard Library has been moved to JSR. See the blog post for details.
function major
import { major } from "https://deno.land/std@0.190.0/semver/mod.ts";

Returns the major version number.

Parameters

v: string | SemVer
optional
options: Options

Returns

number