getMajorVersion
Gets the major of a version such as 9.39.4 or v10.1.0.
Import:
import { getMajorVersion } from '@mnaoumov/obsidian-dev-toolkit/linters/obsidianmd-eslint-nesting';Signature:
function getMajorVersion(version: string): number | nullParameters:
| Parameter | Type | Description |
|---|---|---|
version |
string | The version. |
Returns: number | null — The major, or null when the text does not start with one.