From 8623f4b4f293af83dd1572bdbe01b1cb49b6bf72 Mon Sep 17 00:00:00 2001 From: Tim Reichen Date: Wed, 7 Feb 2024 23:43:44 +0100 Subject: [PATCH] deprecation(semver): deprecate `reverseSort()` (#4280) * initial commit * update --- semver/reverse_sort.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/semver/reverse_sort.ts b/semver/reverse_sort.ts index be7c6092dae9..b0f6c59ea4f4 100644 --- a/semver/reverse_sort.ts +++ b/semver/reverse_sort.ts @@ -2,7 +2,10 @@ import type { SemVer } from "./types.ts"; import { compare } from "./compare.ts"; -/** Sorts a list of semantic versions in descending order. */ +/** + * Sorts a list of semantic versions in descending order. + * @deprecated (will be removed in 0.217.0) Use `versions.sort((a, b) => compare(b, a))` instead. + */ export function reverseSort( versions: SemVer[], ): SemVer[] {