https://stevenleep.github.io/comparison
You want to know if a version is greater than another version? This tool is for you!
Usage Scenarios:
pnpm install @stevenleep/comparison
import { compare } from "@stevenleep/comparison";
const version1 = "1.0.0";
const version2 = "2.0.0";
const result = compare(version1, version2);
result.isGreater; // false
result.status; // negative
the comparison of the version is only one of the application scenarios. Parser at the bottom only provides the ability to install specific characters split. You can expand a lot of things based on this (depending on your own interests and ideas)
Generated using TypeDoc