@jsdevtools/npm-publish
Version:
Fast, easy publishing to NPM
17 lines (16 loc) • 742 B
TypeScript
import type { NormalizedOptions } from "../normalize-options.js";
import type { NpmViewData } from "../npm/index.js";
import { type ReleaseType } from "../results.js";
export interface VersionComparison {
type: ReleaseType | undefined;
oldVersion: string | undefined;
}
/**
* Compare previously published versions with the package's current version.
*
* @param currentVersion The current package version.
* @param publishedVersions The versions that have already been published.
* @param options Configuration options
* @returns The release type and previous version.
*/
export declare function compareVersions(currentVersion: string, publishedVersions: NpmViewData | undefined, options: NormalizedOptions): VersionComparison;